62.1 F
Los Angeles
Sunday, April 21, 2024

Trump Lawyer Resigns One Day Before Trial To Begin

Joseph Tacopina has filed with the courts that he will not represent Donald J. Trump. The E. Jean Carroll civil case is schedule to begin Tuesday January 16,...

Judge Lewis A. Kaplan Issues Order RE Postponement

On May 9, 2023, a jury found Donald J. Trump liable for sexual assault and defamation. The jury awarded Ms. Carroll $5 million in damages. Seven months ago,...

ASUS Announces 2023 Vivobook Classic Series

On April 7, 2023, ASUS introduced five new models in the 2023 Vivobook Classic series of laptops. The top laptops in the series use the 13th Gen Intel® Core™...
StaffPenguin Flight LogRefinement: The Ultimate Guide to PHP Development

Refinement: The Ultimate Guide to PHP Development

On May 12, 2012, I posted a short explanation as to why I was finally learning PHP. Upon further inspection, my favorite line in the post is: “My original code still sucks but I’m starting to read more WP codex and starting to understand arrays a little better.”

My attitude has changed little since that day; my code still sucks but I’m learning. Some of the bulk of the learning is in the processes of creating the code. For example, by January 4, 2013, I was questioning my process for learning. My favorite line from that post is: “Anyway – how did you learn php/mysql? Was it formally or informally? Did you just dive in and write your own scripts first or did you slog through other people’s code?

The series of questions were posed just a few weeks before releasing XenWord. But the important part is that this series of questions led me to PhpStorm, which led me to learning how to use DocBlocks properly to improve the code itself, as well as how to use debug.

My work has become more refined with each iteration of asking questions: scattered ideas come together, features are improved, and strange sequences happen such as writing code comments leading to more questions about why code is written a certain way.

In essence, the whole process regarding learning PHP has been about a cycle of asking questions and trying to answer them.

The greatest catalyst for stretching as a developer has been all of the wonderful people who have supported the hours of development of XenWord. Customers and other developers have been extremely supportive of the work. Their joy has propelled me to take on more challenging aspects of the plugin. Their suggestions have led me to research how to add a feature or remove a nasty bug.

Sometimes, though, there are bumps in the road. For example, the other day a person who purchased XenWord rudely commented on the work as immature. They wanted a refund and thought insulting me was a worthwhile tactic. They could have just asked for the refund and not been dramatic.

Regardless, what the person didn’t understand was that his comments were a great avenue for me to reflect on the direction of the plugin as well as the direction of my learning.

Within a day of the support ticket I was going back through older code and questioning why it was written and did it really work. The hours stretched into the evening but I ultimately discovered a bug in the code – the loading of xenword.css – which had been reported by another developer.

The support ticket led me to ask the following questions — with the very short answers:

  • Are there more bugs in the code? Yes.
  • Are there more challenges to be overcome? Yes.
  • Are there more features needed in the plugin? Yes.
  • Will development continue? Yes.

I’m proud of XenWord. It’s a simple project that has grown from a few lines of code into hundreds of files. With each release of the plugin there has been a refinement as well as a stretch to my abilities.

XenWord 3.0 is now my focus. It’s a refinement of previous releases as well as a stretch into OOP programming and DRY (Don’t Repeat Yourself) ideas. My hope is to release an alpha version to other developers after the directory structure is nailed down and files, methods, and functions are moved around to make room for expanding the features of the plugin.

Let’s hope refinement never ends.

LPH
Layne Heinyhttp://www.layneheiny.com
LPH is a high school physics teacher interested in the Apple iPad and iPhone, Microsoft Surface, Tablet PCs, and other mobile devices. He resides with one large dog who begs for pizza, hamburgers, French fries, and anything else on the dinner table.

Latest news

Related news

2 COMMENTS

2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Admin
7 years ago

Keep going [USER=6][/USER]. XenWord 3.0 is the right direction. Now let’s figure out wp_set_auth_cookie issues 😀

The links between WP and XF are gone again — you must be playing with XenWord again … LOL.

Digital Doctor
7 years ago

Nice to watch a great guy like LPH get even better at coding !