- The directory and (not the class file) are lowercase + underlined and start with lowercase letters;
such as:/application/uctenter/controller
- The class name and the class file capitalize the first letter, the name remains the same;
such as:/application/uctenter/controller/user.php
Class user{
Property
Public userName; Hump name First Letter lowercase
Private properties
Private _userage; Hump name First Letter lowercase
Method
Public Function GetUser () {//hump naming initials lowercase
}
Magic method
function __autoload () {//Double underline "__" starts
}
}
- Naming of Functions | configuration naming | data table and field naming, full lowercase + underline;
such as: Get_user () |url_route_on|wll_user
- Constants name uppercase letters and underscores, for example: App_debug and App_mode;
5. Css uses the bootstrap naming specification , the custom style is : Current page + Location + function [ eg:index_left_news]
PHP Development Specification