mod-rewrite grokage

Anyone out there good with mod-rewrite? I’m trying to do something really simple but I’m not getting some key point. I just wanna do: https://www.moronosphere.com/whatsis redirect to https://www.moronosphere.com/bobsyeruncle I know that’s dead simple but for some reason I can’t get my head around it today.

Anyone out there good with mod-rewrite?

I’m trying to do something really simple but I’m not getting some key point.

I just wanna do:

https://www.moronosphere.com/whatsis
redirect to
https://www.moronosphere.com/bobsyeruncle

I know that’s dead simple but for some reason I can’t get my head around it today.

5 thoughts on “mod-rewrite grokage”

  1. Are you sure you want to do a rewrite as opposed to a redirect?

    Redirect /whatsis https://www.moronosphere.com/bobsyeruncle

    This will send the user to the new location and their location line will read ‘bobsyeruncle’.

    On the other hand, if you want them to see ‘bobsyeruncle’ but still have ‘whatsis’ in their location line, then rewrite is the one you want:

    RewriteEngine on
    RewriteRule ^/whatsis(.*)$ /bobsyeruncle$1 [R,L]

Leave a Reply

Your email address will not be published. Required fields are marked *