-
Notifications
You must be signed in to change notification settings - Fork 19
Conventions
PSR is a specification for defining a coding standard for PHP, similar to RFCs. It is an attempt to standardise the way people use PHP in the hope that different sets of libraries will work (better) together. In addition this should also improve the source-code readability.
- Autoloading Standard - PSR-0
- Basic Coding Standard - PSR-1
- Coding Style Guide - PSR-2
- Logger Interface - PSR-3
- Autoloader - PSR-4
The following websites give some php-specific design tips for new as well as seasoned PHP-Developers. Furthermore they provided tips on how to avoid common pitfalls when building (bigger) php applications.
- Comprehensive "best-practice" reference for PHP
http://www.phptherightway.com/ - General Object-Oriented-Programming Guidelines
http://en.wikipedia.org/w/index.php?title=SOLID_(object-oriented_design) - General Object-Oriented-Programming Design Patterns
http://en.wikipedia.org/w/index.php?title=GRASP_(object-oriented_design) - Model-View-Controller Design in PHP
http://tutorials.lemme.at/mvc-mit-php/ [German]
A code smell is a surface indication that usually corresponds to a deeper problem in the system. A code smell is by definition something that's quick to spot - or sniffable, but code smells don't always indicate a problem. The links below can be used as reference to look for bad design inside your code.
- General code smell overview
http://en.wikipedia.org/wiki/Code_smell - Why you should avoid globals, singletons and static classes: