Forum Moderators: phranque
so that the members profile will automatically look like
http://example.com/suthra
instead of
and also the other links in the site.
Kindly help
Any help is grately appreciated.
Regards.,
Sarathy.s
[edited by: jdMorgan at 2:59 am (utc) on July 6, 2005]
[edit reason] Removed specifics per TOS. [/edit]
Welcome to WebmasterWorld!
The short answer is that you modify the links on your pages to the shorter, friendly format. Then you use mod_rewrite to detect and rewrite those friendly URLs --when requested from your server-- back to the form needed to run your script.
You can change the URLs on your pages either by modifying your database, or by using preg_replace (on PHP pages).
The process may be backwards from what you expected, but mod_rewrite works after a request is received by your server, and before any content is served or any scripts are run. Therefore, mod_rewrite can only change the *filepath* associated with a requested URL, it does not work as an output filter to change page content on-the-fly.
Try a search on WebmasterWorld for '"Friendly URL" RewriteRule [google.com]' for many threads on this subject.
Jim