I'm wondering why a specific code style is 'enforced' while it has nothing to do with interoperability. Libraries with different code styles can be used together without problems. It seems like they are using the PSR to declare they're own style as superior.
PHP: The Right Way
11–20 of 233 posts
Re: PHP: The Right Way
#12Edit: also might be worth adding a bit about steering clear of phpclasses.org as well as w3schools, they bother contain far more bad, than good code.
Re: PHP: The Right Way
#13Something to consider mentioning - there are some in PHP these days that take this sort of stuff a bit too far. Drives me nuts to see people writing classes to encapsulate a 3 column database result. So much overhead and boilerplate.
Re: PHP: The Right Way
#14Re: PHP: The Right Way
#15Hey, nice work. Wouldn't a wiki platform work better however, instead of git? Edit: also might be worth adding a bit about steering clear of phpclasses.org as well as w3schools, they bother contain far more bad, than good code.
Re: PHP: The Right Way
#16That said, it is difficult to bring a legacy code base in line with modern style, though you can improve it over time.
Also, this could benefit from some other gotchas, extremely surprising behavior and best practices for avoiding common pitfalls.
Re: PHP: The Right Way
#17These guidelines won't save you from some bullshit PHP "rules", such as: http://stackoverflow.com/questions/5810168/php-foreach-by-re...
Re: PHP: The Right Way
#18Edit: Everyone talking about databases: paramaterized queries, check them out.
Re: PHP: The Right Way
#19Hey, nice work. Wouldn't a wiki platform work better however, instead of git? Edit: also might be worth adding a bit about steering clear of phpclasses.org as well as w3schools, they bother contain far more bad, than good code.
Re: PHP: The Right Way
#20One point in and its already dead wrong, you never filter input, only output. Edit: Everyone talking about databases: paramaterized queries, check them out.