PHP needs a champion, a Douglas Crockford and book entitled "PHP: The good parts".
PHP faces a lot of similar discrimination that JavaScript did for the longest time. Sure, there are still criticisms for JavaScript but for the most part people have settled and realized that to make JavaScript good you have to write good code. Which is exactly the case for PHP.
The trendiness of PHP bashing exasperates the actual issues of PHP which can easily be abated with good practices.
We need a call for someone to get up and preach the best practices of PHP. And with that, a call for PHP Lint based on those best practices. There are a few individual attempts at providing JS Lint type analysis for PHP files but nothing from anyone with clout. We could use an official analyzer supported by recognized field leaders pushing quality coding practices.
That solution worked well for Javascript, since it is impossible to remove the bad parts since they're embedded in older browsers.
For a server side language I would imagine a better solution is taking the good parts of PHP and creating a new language out of it. Its a very difficult thing to do, and attracting the top members of the PHP community will be challenging -- but could have a useful result.
I hate a lot about PHP, but it definitely has good parts. Python and ruby are great languages - but their style is completely different. I use PHP because there isn't a better alternative that "has the same feel."
The problem is that there are so many dissenting opinions on just what the good parts are.
I for one love PHP's natural templating ability, it's the main reason I use the language, but a lot of people think it encourages mixing business logic and presentation code.
I found that book to be disappointing, not up to O'Reilly's standards, and certainly not in the same league as JS: the Good Parts. I guess they rushed it out to capitalize, which is a shame.
Comments
PHP needs a champion, a Douglas Crockford and book entitled "PHP: The good parts".
PHP faces a lot of similar discrimination that JavaScript did for the longest time. Sure, there are still criticisms for JavaScript but for the most part people have settled and realized that to make JavaScript good you have to write good code. Which is exactly the case for PHP.
The trendiness of PHP bashing exasperates the actual issues of PHP which can easily be abated with good practices.
We need a call for someone to get up and preach the best practices of PHP. And with that, a call for PHP Lint based on those best practices. There are a few individual attempts at providing JS Lint type analysis for PHP files but nothing from anyone with clout. We could use an official analyzer supported by recognized field leaders pushing quality coding practices.
That solution worked well for Javascript, since it is impossible to remove the bad parts since they're embedded in older browsers.
For a server side language I would imagine a better solution is taking the good parts of PHP and creating a new language out of it. Its a very difficult thing to do, and attracting the top members of the PHP community will be challenging -- but could have a useful result.
I hate a lot about PHP, but it definitely has good parts. Python and ruby are great languages - but their style is completely different. I use PHP because there isn't a better alternative that "has the same feel."
The problem is that there are so many dissenting opinions on just what the good parts are.
I for one love PHP's natural templating ability, it's the main reason I use the language, but a lot of people think it encourages mixing business logic and presentation code.
The other crucial reason people like javascript now is because it has a superb implementation in the form of V8.
Also, it has competing implementations with enormous corporations pouring money into them.
I doubt PHP would be in such a sorry state if it was in a similar situation.
Absolutely, if PHP has good parts, I want to know what they are.
It looks like the book for that is already out: http://oreilly.com/catalog/9780596804381
I found that book to be disappointing, not up to O'Reilly's standards, and certainly not in the same league as JS: the Good Parts. I guess they rushed it out to capitalize, which is a shame.
PHP is a legacy programming language. The good part is when new systems are no longer written in PHP!
PHP is roughly the same age as javascript, give or take a few months.