thinkphp按模块区分代码,想要跨模块调用代码(比如logic)。
例如在application下有两个模块 wx ,web,每个模块下都有controller,view,logic等等。想要在web/controller/Index.php 里调用wx/logic/WxLogic.php
<?php
...
class Index{
public function index(){
//wxlogic
$wxLogic=model('wx/WxLogic','logic');
...
...
}
}