本帖最后由 wkhegx 于 2014-06-11 22:18:50 编辑

解决方案 »

  1.   

    请问 $view = $this->controller . '/' . $this->action; 是什么意思? 中间加/ ,是不是除
    中間的/不是運算符,而是一個字符串。
    $view = $this->controller . '/' . $this->action;  的意思是把$this->controller, /, $this->action 拼接起來,然後賦值給$view
    例如
    $this->controll = 'web'
    $this->action = 'index'那麼 $view = 'web/index';
    define ( 'ROOT', dirname ( __FILE__ ) . '/../' ); 这个__FILE__获得当前文件目录,但是后面的 .“/../” 是什么意思??
    ../ 表示父目錄
    例如目錄結構如下
    web/a/b/c/d.php
    然後在d.php 中 dirname ( __FILE__ ) . '/../'  等於 web/a/b/
      

  2.   

    路径。相当于c:\www\index.html 中间的 \
    php里是 / 是路径符, \  是转义符。
      

  3.   

    echo $view;
    echo dirname ( __FILE__ ) . '/../';看看不就知道了?
    不要说你没有php环境