thinkphp3.2.3源碼分析---類自動加載流程圖

 

在命名空間下 new類 如在 Home\Controller命名空間中 new testClass();  在spl_autoload_register($class) 中,$class  等於Home\Controller\testClassblog

而在命名空間下 new類 如在 Home\Controller命名空間中 $class='testClass' ; new $class(); 在spl_autoload_register($class) 中,$class  等於testClassclass

而在命名空間下 new類 如在 Home\Controller命名空間中 new \testClass(); 在spl_autoload_register($class) 中,$class  等於testClasstest

相關文章
相關標籤/搜索