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

相关文章
相关标签/搜索