Forum Moderators: coopster & phranque

Message Too Old, No Replies

Some help on regex?

Just started out using mod_rewrite and using regex...

         

designaweb

4:05 pm on Dec 7, 2002 (gmt 0)

10+ Year Member



I would like to do some mod_rewriting on the following URL's, but I dont know how :(

cheats.php?action=showtitles&platform=n64&letter=T
Should be replaced by:
/n64/T/

and

cheats.php?action=showcheat&platform=n64&letter=T&title=tony hawk pro skater 4
Should be replaced by:
/n64/T/tony_hawk_pro_skater_4.html

I dont know how to do this...

andreasfriedrich

4:50 pm on Dec 7, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



mod_rewrite is useful to convert fake URIs to real ones that do exist on your server. Producing the fake ones that youŽll be using on your actual html pages is up to you or the script that generates those pages.

Andreas

designaweb

5:05 pm on Dec 7, 2002 (gmt 0)

10+ Year Member



Allright, lets put it another way,

A user browses to:

[domain.com...]

But he is not really browsing there, this URL should call for cheats.php?action=showtitles&platform=n64&letter=T

and
[domain.com...]
should call for
cheats.php?action=showcheat&platform=n64&letter=T&title=tony hawk pro skater 4