【发布时间】:2013-05-22 19:34:11
【问题描述】:
在 htaccess 以下条目中将旧域停放在我的新站点(域)中:
RewriteCond %{HTTP_HOST} ^(www.)?mynewsite.com$
RewriteRule ^(/)?$ mynewsite.com/index.php [L]
RewriteCond %{HTTP_HOST} ^old\-site\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.old\-site\.com$
RewriteRule ^/?$ "http\:\/\/mynewsite\.com" [R=301,L]
是人们会喜欢的旧链接: old-site.com/support.php、old-site.com/en/index.php、old-site.com/en/support.php、old-site.com/msg/text.php 当我点击它时,出现错误 ERROR 404。
如何将它们重定向到新域上的相同地址? old-site.com/support.php -> mynewsite.com/support.php, old-site.com/en/index.php -> mynewsite.com/en/index.php
【问题讨论】:
-
当您说“停放”时,您是否可以控制旧域的
.htaccess文件,或者您是否正在使用注册商的停放功能?
标签: .htaccess