在用户单击了末尾没有.asp后缀的i.e. http://super.cash.com/boom url后,我如何将他们重定向到i.e (http://super.cash.com/boom.asp)页面?
发布于 2013-11-19 14:15:32
您可以在根.htaccess文件中尝试此规则:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.asp -f
RewriteRule ^(.+?)/?$ $1.asp [L]301重定向的:
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.asp -f
RewriteRule ^(.+?)/?$ $1.asp [L,R=301]https://stackoverflow.com/questions/20063583
复制相似问题