开发者

RewriteRule at htaccess wrong redirect

ive this rules at htaccess

RewriteEngine On
RewriteCond %{HTTP_HOST} ^site.com [NC]
RewriteRule ^(.*)$ http://www.site.com/$1 [L,R开发者_如何学C=301]
RewriteCond %{QUERY_STRING}  ^$
RewriteRule ^warcraft$  www.site.com/forumdisplay.php?f=480 [R=301,NE,NC,L]

issue happend when redirect warcraft its redirect to

http://www.site.com/home/site/public_html/www.site.com/forumdisplay.php?f=480

any tip ?


I suppose you want to redirect it to http://www.site.com/forumdisplay.php?f=480
If so put it in your .htaccess file:

RewriteCond %{QUERY_STRING}  ^$
RewriteRule ^warcraft$  http://www.site.com/forumdisplay.php?f=480 [R=301,NE,NC,L]


You must provide the full URL including protocol in your rule, in this case http://www.site.com/.....

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜