Forum Moderators: phranque

Message Too Old, No Replies

How to catch the parameters

         

Gian04

5:20 am on Aug 31, 2009 (gmt 0)

10+ Year Member



I have a page http://www.example.com/index.php&param1=anything_here1&param2=anything_here2

How can I modrewrite it so that it will look like this
http://www.example.com/anything_here1/anything_here2

anything_here1 and anything_here2 can be a string (with numbers, letters, special chars etc)

Thanks

jdMorgan

11:52 am on Aug 31, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You can't mod_rewrite it to "look different." Whatever URL appears on your page is the 'real' URL -- Your pages define the link URLs.

What you can do is to change the URLs you publish on your pages, and then use mod_rewrite to 'map' those new "SEO-friendly" URLs back to the correct dynamic script-plus-query-string filepath on your server.

See the tutorials in our Apache Forum Library for more information.

Jim