= 0) { return spl_autoload_register(array('PHPExcel_Autoloader', 'Load'), true, true); } else { return spl_autoload_register(array('PHPExcel_Autoloader', 'Load')); } } // function Register() /** * Autoload a class identified by name * * @param string $pClassName Name of the object to load */ public static function Load($pClassName){ if ((class_exists($pClassName,FALSE)) || (strpos($pClassName, 'PHPExcel') !== 0)) { // Either already loaded, or not a PHPExcel class request return FALSE; } $pClassFilePath = PHPEXCEL_ROOT . str_replace('_',DIRECTORY_SEPARATOR,$pClassName) . '.php'; if ((file_exists($pClassFilePath) === FALSE) || (is_readable($pClassFilePath) === FALSE)) { // Can't load return FALSE; } require($pClassFilePath); } // function Load() }