开发者

htaccess url shortening works locally not on server

开发者 https://www.devze.com 2023-03-14 00:01 出处:网络
I wonder if anyone can take a look at this htaccess and tell me why it should work on a localhost but not on server

I wonder if anyone can take a look at this htaccess and tell me why it should work on a localhost but not on server

Options +FollowSymlinks
RewriteEngine On
RewriteBase /subdirectory


RewriteCond %{RE开发者_StackOverflow社区QUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^news(.*)$ news.php?q=$1 [L,QSA]

RewriteRule ^view/([^/]+)/([^/]+).html /view.php?content_id=$1&content_id=$2 [NC]


Try to remove RewriteBase /subdirectory or rename it to RewriteBase /.

0

精彩评论

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