Php and road ahead

“I don’t know how to stop it, there was never any intent to write a programming language […] I have absolutely no idea how to write a programming language, I just kept adding the next logical step on the way.” – Rasmus Lerndof. Creator of Php language.

Hate it or love it, if you are into application development you cannot ignore Php. The 2012 blog of Php: Fractal of bad design did scare a lot of developers in 2012 and even a year or 2 later. Lot’s of us thought the career path of Php developers is over but fast forward to 2019, we are only seeing the community and language grow and get more popular. If we do a quick online search the total number of Php developers world wide is around 5.5 million(source). While this number looks great, has the language really evolved and is it really close to it’s other counterparts like Node.JS or Python? Let’s uncover this question in the next few paragraphs.  

Php today and beyond

For the next few minutes I would like you to just stay neutral and read on. Yes there are still concerns but let us look at the evolution and understand the better side. 

  1. Since its first release in June 1995 there has been 19 releases as of Php 7.3
  2. Php 7.4 is slated to go live in November 2019 and Php 8.0 is expected to go live by Q4 of 2020 or Q1 of 2021
  3. Php has wide variety of framework to choose based on your project needs. From full-stack to component based to bit of both to the minimalist type with a very active community support
  4. Php performance has increased significantly do read the benchmark details shared at Kinsta
  5. Static ananlyzer is much matured today compared to what it was during the days of Php 5^

Elephant-image

A close look at Php today

Php today has lots of improvements and lots of new features, some of the key new features of Php7^ are shared below:

  1. Scalar type declarations
  2. Return type declarations
  3. Null coalescing operator
  4. Spaceship operator
  5. Constant arrays using define()
  6. Anonymous classes
  7. Unicode codepoint escape syntax
  8. Closure::call()
  9. Unserializing objects on untrusted data
  10. Unicode character manipulation
  11. Expectations
  12. Group use declarations
  13. Generator delegation

The list is more, please do read the official documentation on Php.net

On Tooling

Apart from the improvement in language, there has been a constant improvement in the tooling area. A static analysis tool is a software that reads your code without actually executing it. The tool searches for patterns in your code that could lead to various issues. Some of the popular open source Static analysis tools include:

  1. PhpStan
  2. Psalm
  3. PMF
  4. RIPS
  5. Exakat

While certainly things have improved drastically in Php, but we need to live with the fact that there still are issues and 20 years of legacy. But the bottom line is if you are looking for a decent application development and availability of pool of resources Php is a good choice.  

Learn from yesterday, live for today, hope for tomorrow. The important thing is not to stop questioning.

– Albert Einstein