Apache htaccess 301重定向特殊字符

时间:2015-10-28 17:06:07

标签: php apache .htaccess mod-rewrite redirect

真正挣扎于此,htaccess中的所有301重定向(没有特殊字符的重定向)正在与此分开。我需要从

重定向

/folder1/departmentpage.html/customerx/_438081/1/Sofabeds%2520for%2520Small%2520%252D%2520Medium%2520or%2520Large%2520Rooms

http://www.newsite.com/sofabeds

非常感谢任何帮助。

1 个答案:

答案 0 :(得分:1)

你可以做一些简单的事情。

RewriteCond %{REQUEST_URI} ^(.*)Sofabeds(.*)
RewriteRule ^ http://www.newsite.com/Sofabeds [R=301,L]