Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

TL;DR Your dad's PHP is no longer the current PHP. The language itself has been thoroughly modernized, made more consistent, bug free and performant. There is nothing better than a piece of software that keeps getting improved decade after decade borne out of real developer needs and experience.

- Type annotations are integrated and work well with PHP now. This results in a kind of scripty Java OOP that is more succinct and type checked ! (it is possible to write PHP without types when you want metaprogramming features also)

- Many inconsistencies in the design of the language (OOP, function naming etc.) have been resolved/smoothed out

- The language recognises the inherent problems with `null` and allows you to make type annotations that rule out null. This is my smell test for a language BTW -- golang for instance does not seem to have a good story for null.

- PHP Language developers have been really good about increasing performance year after year

- Lots of software like web frameworks and CMSes continue to be based on PHP

And -- the greatest part of the design -- PHP remains the best example of the "shared nothing" architecture. An architecture that allows you to scale your application easily.



> Your dad's PHP is no longer the current PHP.

I am pretty much in the "your dad" category here. Where best to start learning how PHP has changed since I used it?

There are things that appeal to be about PHP.


Build something with symfony or laravel. In this space PHP is used in the modern way. Don't look at WordPress, Pimcore, WooCommerce et al. They're pretty much stuck with old PHP.

That said, you can still shoot yourself in the foot with PHP. The dark alleys are all still there.


Thanks. I never want to look at WP again so that suits me :)

I looked at Symfony a few years back and it looked nice. if it has kept up with modern PHP it looks like a nice choice.


I would say that symfony is the base of modern PHP. Laravel and others can only be as beautiful as symfony is.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: