Expert advice: tips for becoming a good PHP developer
December 1, 2017

Expert advice: tips for becoming a good PHP developer

PHP is a language particularly suitable for someone at the start of a career.  Due to the low entry threshold and specifics of the language, many developers begin their professional path there, but then get lost and do not learn to code properly.

Like all languages, PHP encompasses both strong and weak points. While there are many discussions of PHP’s weak sides, such as memory leaks, scalability and speed, the bigger issue I can identify from my experience is an implicit one.

General programming recommendations

My advice for newbie developers is that learning to code properly is more important than learning the syntax. You should concentrate on general programming practice as much, if not more, than learning PHP itself.  Here are some of these important practical elements that you will not understand in the beginning, but should nonetheless learn to master:

  1. Data structures – Similar to design patterns, data structures help you solve certain problems.  Much too often, developers do not know the available data structures, nor when to use them. This causes poor performance, and ugly code.
  2. Algorithms – You will want to minimize your algorithm complexity to improve performance. In many cases developers use algorithms provided by 3rd party libraries  without understanding how they work. While studying at university, I spent time doing what is called algorithmic programming and taking part in ACM ICPC competitions, which helped me to achieve better understanding. (By the way, it isn’t necessary to win.  Learning how to solve just a subset of those challenges will help you a lot.)
  3. SQL – In large projects, there is usually a specific person handling database queries, especially complicated ones. Until you are fortunate enough to benefit from that type of staffing, you will need to do this yourself. As you become more experienced, you should understand how the ORM transforms requests into queries. Sometimes it is better to write your own.
  4. Patterns – Concentrate on when to use patterns and when not to use.  You want to reach the level where you can automatically recognize when certain patterns should be used. (Re-read each time you think you’ve reached a new level).  
  5. Web Functionality – You should direct attention to “How the web works” that is on a comfortable level for you. You should start with basics and get deeper into each subject with time.
      1. How requests travel from your browser to the server and data is returned.
      2. Cookies/Sessions.
      3. SSL/HTTPS.
  6. Other Principles – Here are some principles that are recommended to follow:
      1. DRY.
      2. KISS.
      3. SOLID.
      4. OOP principles.
  7. English – Whether for reading manuals, understanding requirements, or for talking with the clients, you will need it.

PHP specific advice

When developing, it is extremely rare that one will code using pure PHP.  Generally, you would be using one of the following approaches:

  1. Frameworks (such as Symfony, Laravel, ZF, Yii)

  2. CMS (such as WordPress, Drupal, Typo3) 
  3. Platforms (such as Magento)

By understanding how to develop in PHP, one should be able to develop in either of the above-mentioned options. Nevertheless, there is a certain learning curve for each of these approaches, meaning efficiency in one technology stack does not automatically mean efficiency in another.  Take your time.  Do not rush to learn them all at once.  Choose one that fits the way you think. Usually developers would specialize in only 1 or 2 of them.

In terms of literature, there is a lot of reading out there for general programming, algorithms, patterns, etc., and much has been recommended in a previous series of DOU articles for other technologies. I can recommend the following PHP specific sites for starters.

  1. http://php.net/manual/en/
  2. http://www.phptherightway.com/

Incidentally, I just needed the documentation from the official php.net to pass the PHP Certification.

Deputy Production Director, CoreValue

Tags

CoreValuePHP

Share


Recent Articles

It’s all about Quality: Migration and Data Validation Testing

June 14, 2019 | Yuliya Zubenko, Senior QA Engineer

There exists a lot of reasons why organizations are forced to migrate their data. Data migration can be performed manually or by using special tools. The process becomes more challenging if the migration is to be performed for a complex application with huge amount of data. Data Accuracy is a key aspect that should be […]

Hot and Trendy: Google Teams up with Looker

June 10, 2019

The IT world is stirred up with the latest plans of Google to acquire Looker, a data analytics platform. Google LLC announced its agreement with Looker to join forces in the development of a comprehensive data analytics solution for customers.   Looker, a business analytics and data intelligence platform, empowers organizations to draw insights from […]

Contact Us

By submitting this form you acknowledge that you agreed to our Cookies and Privacy Policy.