How to register namespaces (with PHP 5.3) in the Symfony 1.4 for the autoloader class feature (like the Symfony 2.0)?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can use Autoloader from Symfony2 in Symfony 1.4 framework.
1. Copy Symfony2 classloaders to vendor directory of your Symfony 1.4 sandbox project:
2. Modify your SF_ROOT_DIR/config/ProjectConfiguration.class.php file as follows:
3. Register desired namespaces:
eg. I want to load class:
Filename must be:
and registered namespace as follows: