首页 > Web开发 > 详细

thinkphp nginx 配置

时间:2016-06-23 12:53:32      阅读:220      评论:0      收藏:0      [点我收藏+]
thinkphp convention配置:
‘URL_MODEL‘ => ‘2‘, //URL模式

nginx rewrite配置:
 if (!-e $request_filename) {
   rewrite  ^(.*)$  /index.php?s=$1  last;
   break;
    }

如果你的ThinkPHP安装在二级目录,Nginx的伪静态方法设置如下,其中youdomain是所在的目录名称
location /youdomain/ {
        if (!-e $request_filename){
            rewrite  ^/youdomain/(.*)$  /youdomain/index.php?s=$1  last;
        }
    }
 

thinkphp nginx 配置

原文:http://www.cnblogs.com/yangcclg/p/5610141.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!