开发者

What am I doing wrong in this subdomain redirect?

开发者_Go百科

What I need is as follows: People visiting 201101.donateaday.net should be sent to http://donateaday.net/2011/01/bla-kors-norge/

I tried: Options +FollowSymLinks

RewriteEngine on

RewriteCond %{HTTP_HOST} ^201101.donateaday.net/

RewriteRule ^(.*)$ http://donateaday.net/2011/01/bla-kors-norge/ [r=301,l]

However, this does not seem to work. What am I doing wrong?

Evert


It seems your RewriteCond has some characters too many. Try this instead:

RewriteCond %{HTTP_HOST} 201101\.donateaday\.net

The dots are escaped so that they match literal dots, instead of any character.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜