Naming conventions in PHP frameworks and cms .

@mit $ingh. December 22, 2014 Comments

 

 Naming conventions
PHP ProjectClassesMethodsPropertiesFunctionsVariables
Akelos FrameworkPascalCasecamelCasecamelCaselower_caselower_case
CakePHP FrameworkPascalCasecamelCasecamelCasecamelCasecamelCase
CodeIgniter FrameworkProper_Caselower_caselower_caselower_caselower_case
Concrete5 CMSPascalCasecamelCasecamelCaselower_caselower_case
Doctrine ORMPascalCasecamelCasecamelCasecamelCasecamelCase
Drupal CMSPascalCasecamelCasecamelCaselower_caselower_case
Joomla CMSPascalCasecamelCasecamelCasecamelCasecamelCase
modx CMSPascalCasecamelCasecamelCasecamelCaselower_case
Pear FrameworkPascalCasecamelCasecamelCase  
Prado FrameworkPascalCasecamelCasePascal/camel lower_case
SimplePie RSSPascalCaselower_caselower_caselower_caselower_case
Symfony FrameworkPascalCasecamelCasecamelCasecamelCasecamelCase
WordPress CMS   lower_caselower_case
Zend FrameworkPascalCasecamelCasecamelCasecamelCasecamelCase

 

I suggest all of you to follow the below naming conventions :  

  • ClassName
  • methodName
  • propertyName
  • function_name (meant for global functions)
  • $variable_name
  • PHP
  • naming-convention
  • framework