Reply to seeking mod_rewrite solution

Your name:

Reply:


Posted by joelbyrd on 03/02/06 01:27

I have a people-networking type site in which each user has their own
profile page, with their user id encoded. So, for example, the web
address of their page might look like
"www.example.com/my_profile.php?user_id=fdjkhfh2489298hf298h3s0dhfxj".
I want the users to be able to choose their own web address that would
look like "www.example.com/Joel", and then when they type in that
address, they are automatically redirected to their profile page with
the more complex address.

I believe mod_rewrite is the solution to this?

Reading a little bit about mod_rewrite, I believe the rule I want is
something like the following:

RewriteRule ^/(.*) /redirect_user.php?user_name=$1

So 2 simple questions:
1) does this rule look like what I want?
2) how do I install and hook up the module, and do I write this rule
in the .htaccess file?

I'm brand new to mod_rewrite, so any help would be appreciated.

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация