Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

ServerGrove Blog:
Configuring Symfony to use Zend Framework 1.8.0 new Autoloader
May 01, 2009 @ 20:56:37

This new post on the ServerGrove blog today looks at using the updated Zend_Loader component of the Zend Framework from inside a Symfony application.

Zend Framework 1.8.0 was released yesterday and if you are using it within a Symfony project, you need to know something: Starting on 1.8.0 Zend_Load::autoload() is deprecated and will be removed on 2.0.0.

With the updated loader, if you'd like to use it inside Symfony, you need to change the function you're using to autoload via a call to spl_autoload_register. Point this at the Zend Framework code and you should be good to go.

tagged: symfony zendframework autoloader framework splautoloadregister

Link:

Martynas Jusevicius' Blog:
PHP 5 features: Class autoloading
Dec 07, 2007 @ 16:29:00

Martynas Jusevicius continues his look at the enhanced features that PHP5 has to offer with this post focusing on the ability to autoload classes that haven't been defined yet.

Continuing the series about useful features in PHP 5, another overlooked one is class autoloading. [...] Basically, you get a class name as a parameter in your __autoload() function, and using it you have to figure out the path to the actual class file and include it.

He includes both a description and an example of some code in action and even points out something that can help to make for cleaner, more organized code - the ability to register more than one autloader with the spl_autoload_register function.

tagged: php5 feature class autoloading splautoloadregister php5 feature class autoloading splautoloadregister

Link:

Martynas Jusevicius' Blog:
PHP 5 features: Class autoloading
Dec 07, 2007 @ 16:29:00

Martynas Jusevicius continues his look at the enhanced features that PHP5 has to offer with this post focusing on the ability to autoload classes that haven't been defined yet.

Continuing the series about useful features in PHP 5, another overlooked one is class autoloading. [...] Basically, you get a class name as a parameter in your __autoload() function, and using it you have to figure out the path to the actual class file and include it.

He includes both a description and an example of some code in action and even points out something that can help to make for cleaner, more organized code - the ability to register more than one autloader with the spl_autoload_register function.

tagged: php5 feature class autoloading splautoloadregister php5 feature class autoloading splautoloadregister

Link:


Trending Topics: