This follows our old norm, do not use it of your using PrestaShop 1.6.1.0+
Since version 1.6.1.0 of PrestaShop, we are using the PSR-2 Coding Style Guide as our coding standards.
All PrestaShop Coding Standards have been introduced here.
-
Install phpcs: pear install PHP_CodeSniffer
-
Find your PEAR directory: pear config-show | grep php_dir
-
You can run PHP CodeSniffer against an entire directory: phpcs --standard=PSR2 PrestaShop/classes/