关于tp3.2.2的nginx配置 大神们,今天我上线一个项目出现了点问题,就是主页能显示,跳转都是404,我知道是nginx中的rewrite的问题,请问大神3.2.2中nginx配置里面的rewrite规则应该怎么进行配置啊,这个问题卡了好久,url怎么才能重定向。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 比如这样的网址http:://www.test.com/mall/product/1.htmllocation / { rewrite ^([^\.]*)/(\w+)/(\w+)/(\w+)\.html$ $1/?m=home&c=$2&a=$3&id=$4 last;}访问的就是 home模块,mall控制,product方法,id 参数是 1 location /{ index index.html index.htm index.php; if (-e $request_filename) { break; } if (!-e $request_filename) { rewrite ^/(.*)$ /index.php/$1 last; break; } }为何项目都上线了,还不知道如何配置? 我的网站现在可以跳转了,但是除了主页,其他页面所有的样式都不好使了,ajax也坏掉了,生无可恋了求大神加下我的QQ可以帮我我这个新手一下,我很着急啊!!!QQ964901822 小白问题:服务器是Linux系统,本地开发环境也必须是Linux吗? wampserver 问题 关于PHP调用类方法的效率问题 php 生成静态页面缓存ob_end_clean()问题 附原码 本人初学希望不要见笑 utf8页面用GET的方法传中文字问题 jpgraph中没有jpgraph_odo.php文件 关于smart模板使用的嵌套问题。 如何统计某一个软件的下载次数 正则急问:请完整替换其中的[]为<> 怎样避免使用全局变量问题请大家讨论!! winserver08 wamp环境中经常会在页面头部多出现“1”字符,该如何排查? 通达信day文件 成交额字段
http:://www.test.com/mall/product/1.htmllocation / {
rewrite ^([^\.]*)/(\w+)/(\w+)/(\w+)\.html$ $1/?m=home&c=$2&a=$3&id=$4 last;
}
访问的就是 home模块,mall控制,product方法,id 参数是 1
index index.html index.htm index.php;
if (-e $request_filename) {
break;
}
if (!-e $request_filename) {
rewrite ^/(.*)$ /index.php/$1 last;
break;
}
}
为何项目都上线了,还不知道如何配置?