function __autoload($class) {
if (strpos($class, 'CI_') !== 0) {
if (file_exists($file = APPPATH . 'core/' . $class . php)) {
include $file;
}
}
}
已弃用:__autoload() 已经被弃用,请使用spl_autoload_register() 和致命错误:在codeigniter中无法重新声明__autoload()错误
__autoload()
并使用spl_autoload_register()
。有什么更清晰的陈述方式吗? - Ken White