Re:Signs of Crappy PHP Software
by robryan on Sunday July 04, 2010 @11:48AM
(#1485833)
Not only that but depending what kind of db wrapper class you have you probably want it to be modified by the code that touches it. Sure you could pass it around, I guess it depends on how many people touch the code.
Personally I global the database wrapper, the user session class and config stuff (which yes I could use constants). Although if the code base I'm referring to wasn't 95% me coding I would probably consider using global less.
Personally I global the database wrapper, the user session class and config stuff (which yes I could use constants). Although if the code base I'm referring to wasn't 95% me coding I would probably consider using global less.