Welcome Guest, Not a member yet? Register   Sign In
Help writing a 301 redirect please
#1

[eluser]kevinprince[/eluser]
Hi,

Hopefully someone has a great understanding of the world of mod_rewrite.

I currently have a rule which looks like this:

Code:
Redirect 301 /folder http://old.domain.com/folder
The problem is I need to add [NC, L] I think to tell it to ignore capitals and any future rules.

I tried:

Code:
Redirect 301 /folder http://old.domain.com/folder [NC, L]

But it didnt work, Ive got about 20 of these redirects and its annoying me greatly!
#2

[eluser]kevinprince[/eluser]
Bump :/
#3

[eluser]tonanbarbarian[/eluser]
I always find that manuals are very helpful at times like these
http://httpd.apache.org/docs/
Choose your version of apache then go to directives and search for redirect

There you will see a few interesting things

1. It does not support any of those extras like [N,L], that is only in the rewrite engine, which might be better for you
2. apache 2.0 docs state that the old url i.e. /folder is case sensitive, as does the 2.2 docs. !.3 does not say but I think it is fairly safe to assume it is case sensitive too

You might want to look at the mod_rewrite directives to use instead if you are having problems with case sensitivity
So look up RewriteRule
#4

[eluser]johnwbaxter[/eluser]
I have no idea what the folder bit means or does. Is this put in by you or is this a 301 switch?

What exactly are you trying to do. In english.




Theme © iAndrew 2016 - Forum software by © MyBB