Forum Moderators: phranque

Message Too Old, No Replies

mod rewrite

         

regevlio

9:18 am on Sep 25, 2011 (gmt 0)

10+ Year Member



Hi There

I cant figure this one out
I have the following link on my site

www.#*$!x.com/play?id=5
www.#*$!x.com/play?id=6

How can i make it look like

www.#*$!x.com/name-of-thegame.html

your help will be highly appreciated

thanks
Lior

regevlio

9:22 am on Sep 25, 2011 (gmt 0)

10+ Year Member



www.yyyy.com/play?id=5
www.yyyy.com/play?id=6

g1smd

9:23 am on Sep 25, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



This is a question that's asked almost every day here.

You'll need to rewrite (that's rewrite, not redirect) the request to a special PHP script that looks up the new name then sends the 301 and location headers back to the browser.

Check recent threads, and post your code.


Use example.com in the forum to stop URL auto-linking.

lucy24

7:53 pm on Sep 25, 2011 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Wait. Did you mean link on your site, or link to your site? If it's your own link, you should change it to the form you want the user to see, with no need for redirecting.

If you are changing lots and lots of them at once, you can certainly call in php to your assistance for a one-time fix. But redirecting should only happen to people following links from outside your site.