查看phpinfo信息。属于InitPHP框架工具类,需要通过$this->getUtil()方法获取
$phpinfo = $this->getUtil('phpinfo');
| 参数 | 类型 | 是否必须 | 描述 |
|---|
class indexController extends Controller {
public $initphp_list = array('test');
public function run() {
$phpinfo = $this->getUtil('phpinfo');
$phpinfo->get_phpinfo();
$this->getTestService()->test();
$this->view->display(); //模板显示
}
public function test() {
echo 'Hello World';
}
/**
* @return testService
*/
private function getTestService() {
return InitPHP::getService('test','test');
}
}