PHP best practices for naming conventions
- by alex
I recently started these naming conventions..
all functions & variables = camelCase
constants with define() = ALL_CAPS_AND_UNDERSCORES
Now I see a lot of other people mix up camelCase and underscores and they seem to have some sort of convention to it... What do you use and what is best? I've heard that public and private functions should have underscores before some.. I assume private have 2 underscores as in __construct() ?
Thank you!