Best solution for __autoload
- by tpk
As our PHP5 OO application grew (in both size and traffic), we decided to revisit the __autoload() strategy.
We always name the file by the class definition it contains, so class Customer would be contained within Customer.php. We used to list the directories in which a file can potentially exist, until the right .php file was found.
This is…