Expert Advice: Tips for Becoming a Good PHP Developer

PHP tips for developers

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 that can be identified from experience is an implicit one.

General programming recommendations

A bit of 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. Algorithmic programming and ACM ICPC competitions help to achieve better understanding of algorithms. (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. The following PHP specific sites for starters are recommended:


Incidentally, the documentation was needed from the official to pass the PHP Certification.

Have a project in mind and not sure how to get started?
Take the first step.
Back to overview