diff options
author | xue <> | 2006-11-04 03:33:00 +0000 |
---|---|---|
committer | xue <> | 2006-11-04 03:33:00 +0000 |
commit | 3850edb7440923c6296026c658d53f44faceff55 (patch) | |
tree | 3b65305deeac2cc151d2d7fcad9f5d93af2a2207 /framework/prado.php | |
parent | e34500aaf1a58b05ddcc6421631a586ca9c99b77 (diff) |
merge from 3.0 branch till 1489.
Diffstat (limited to 'framework/prado.php')
-rw-r--r-- | framework/prado.php | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/framework/prado.php b/framework/prado.php index 2eeda291..4cf3ab3e 100644 --- a/framework/prado.php +++ b/framework/prado.php @@ -7,7 +7,7 @@ * available functionalities that enable PRADO component model and error handling mechanism.
*
* By including this file, the PHP error and exception handlers are set as
- * PRADO handlers, and an __autoload function is provided that automatiically
+ * PRADO handlers, and an __autoload function is provided that automatically
* loads a class file if the class is not defined.
*
* @author Qiang Xue <qiang.xue@gmail.com>
@@ -34,15 +34,12 @@ if(!class_exists('Prado',false)) }
/**
- * Defines __autoload function if not defined.
+ * Registers the autoload function.
+ * Since Prado::autoload will report a fatal error if the class file
+ * cannot be found, if you have multiple autoloaders, Prado::autoload
+ * should be registered in the last.
*/
-if(!function_exists('__autoload'))
-{
- function __autoload($className)
- {
- Prado::autoload($className);
- }
-}
+spl_autoload_register(array('Prado','autoload'));
/**
* Initializes error and exception handlers
|