使用新的自动加载机制

This commit is contained in:
huangdijia
2015-03-04 08:39:11 +08:00
parent 3af5f0a766
commit 8f36fc7089
3 changed files with 3 additions and 3 deletions

View File

@@ -48,7 +48,7 @@ class Image {
*/
static public function init($type = 'Gd', $imgname = null){
/* 引入处理库,实例化图片处理对象 */
$class = '\\Think\\Image\\Driver\\'.strtolower($type);
$class = '\\think\\image\\driver\\'.strtolower($type);
self::$im = new $class($imgname);
return self::$im;
}

View File

@@ -19,7 +19,7 @@ class Parser {
// 解析内容
static public function parse($content,$type){
if(!isset(self::$handler[$type])) {
$class = '\\Think\\Parser\\Driver\\'.strtolower($type);
$class = '\\think\\parser\\driver\\'.strtolower($type);
self::$handler[$type] = new $class();
}
return self::$handler[$type]->parse($content);

View File

@@ -23,7 +23,7 @@ class Transform {
*/
static private function init($type){
if(!isset(self::$handler[$type])) {
$class = '\\Think\\Transform\\Driver\\' . strtolower($type);
$class = '\\think\\transform\\driver\\' . strtolower($type);
self::$handler[$type] = new $class();
}
}