四虎影视在线影院在线观看,小s货再浪些再咬紧点h,国产精品水嫩水嫩,97精产国品一二三产区

Board logo

標(biāo)題: [求助] .htaccess與nginx規(guī)則問(wèn)題 [打印本頁(yè)]

作者: baike    時(shí)間: 2016-9-13 22:07     標(biāo)題: .htaccess與nginx規(guī)則問(wèn)題

下面是.htaccess規(guī)則  用apache環(huán)境訪問(wèn)正常
RewriteEngine On

RewriteRule ^index.html$ /index.php [L]


RewriteRule ^search.html$ search/search_kw.php [L]
RewriteRule ^search/(.*).html$ search/search_article.php?p=$1  [L]

RewriteRule ^m/(.*)-m.html$ m/m_article.php?p=$1  [L]
RewriteRule ^m/(.*).html$ m/index.php?c=$1  [L]

RewriteRule ^search/(.*)/([0-9]+)/$ search/search.php?kw=$1&t=1&page=$2  [L]
RewriteRule ^search/(.*)/$ search/search.php?kw=$1&t=1 [L]

RewriteRule ^tags/(.*)/([0-9]+)/$ search/search.php?kw=$1&t=2&page=$2  [L]
RewriteRule ^tags/(.*)/$ search/search.php?kw=$1&t=2 [L]

RewriteRule ^list/(.*)/([0-9]+).html$ list.php?c=$1&page=$2  [L]
RewriteRule ^list/(.*).html$ list.php?c=$1&page=1  [L]


RewriteRule ^article/20(.*)/(.*).html$ article/article.php?riqi=$1&p=$2 [L]
RewriteRule ^(.*)/20(.*)/(.*).html$ article.php?riqi=$2&p=$3&c=$1 [L]

RewriteRule ^article/(.*)/([0-9]+).html$ article/list.php?c=$1&page=$2  [L]
RewriteRule ^article/(.*).html$ article/list.php?c=$1 [L]
RewriteRule ^tags/index.html$ tags/index.php [L]

RewriteRule ^(.*).html$ search/search_article.php?p=$1  [L]



下面是nginx規(guī)則  怎么調(diào)試都顯示403錯(cuò)誤
rewrite ^/index.html$ /index.php last;


rewrite ^/search.html$ search/search_kw.php last;
rewrite ^/search/(.*).html$ search/search_article.php?p=$1 last;

rewrite ^/m/(.*)-m.html$ m/m_article.php?p=$1 last;
rewrite ^/m/(.*).html$ m/index.php?c=$1 last;

rewrite ^/search/(.*)/([0-9]+)/$ search/search.php?kw=$1&t=1&page=$2 last;
rewrite ^/search/(.*)/$ search/search.php?kw=$1&t=1 last;

rewrite ^/tags/(.*)/([0-9]+)/$ search/search.php?kw=$1&t=2&page=$2 last;
rewrite ^/tags/(.*)/$ search/search.php?kw=$1&t=2 last;

rewrite ^/list/(.*)/([0-9]+).html$ list.php?c=$1&page=$2 last;
rewrite ^/list/(.*).html$ list.php?c=$1&page=1 last;


rewrite ^/article/20(.*)/(.*).html$ article/article.php?riqi=$1&p=$2 last;
rewrite ^/(.*)/20(.*)/(.*).html$ article.php?riqi=$2&p=$3&c=$1 last;

rewrite ^/article/(.*)/([0-9]+).html$ article/list.php?c=$1&page=$2 last;
rewrite ^/article/(.*).html$ article/list.php?c=$1 last;
rewrite ^/tags/index.html$ tags/index.php last;

rewrite ^/(.*).html$ search/search_article.php?p=$1 last;





歡迎光臨 WDlinux官方論壇 (http://cd-genova.com/bbs/) Powered by Discuz! 7.2