【发布时间】:2014-07-25 17:32:12
【问题描述】:
我正在尝试重定向多个 URL ...
http://download.stevechab.com/album/allergy 到 http://histamines.bandcamp.com/album/allergy
http://download.stevechab.com/album/reallergy-remix-album到http://histamines.bandcamp.com/album/reallergy-remix-album
http://download.stevechab.com/album/vanillarabb到http://arabbi.bandcamp.com/album/vanillarabb
http://download.stevechab.com/album/arabb到http://arabbi.bandcamp.com/album/arabb
我试过了:
RewriteEngine on
rewritecond %{http_host} ^download\.stevechab\.com/album/allergy [nc]
rewriterule ^(.*)$ http://histamines.bandcamp.com/album/allergy$1 [r=301,nc]
Redirect 301 http://download.stevechab.com/album/allergy http://histamines.bandcamp.com/album/allergy
没有用。我可以访问 stevechab.com htaccess 文件,但不能访问 download.stevechab.com htaccess 文件。有没有办法做这个重定向?
这是我的整个 htaccess 文件的样子...
ErrorDocument 404 http://www.stevechab.com
Options +FollowSymlinks
RewriteEngine on
rewritecond %{http_host} ^stevechab.com [nc]
rewriterule ^(.*)$ http://www.stevechab.com/$1 [r=301,nc]
Redirect 301 http://stevechab.com http://www.stevechab.com
rewritecond %{http_host} ^download\.stevechab\.com/album/allergy [nc]
rewriterule ^(.*)$ http://histamines.bandcamp.com/album/allergy$1 [r=301,nc]
Redirect 301 http://download.stevechab.com/album/allergy http://histamines.bandcamp.com/album/allergy
谢谢!
史蒂夫
【问题讨论】: