[users@httpd] Can I have "fake" URLs with mod_rewrite???

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am not new to Apache but I am by no means a guru. And I have never
used the rewrite module. So I have this question.

I have a situation where I would like to add user webpages dynamically.
But I do not want to restart Apache every time. The web page(s) will
most likely all be the same but with some display information specific
to a user. I was wondering if mod_rewite would let me do the following.

www.sm.com/lo/bob
www.sm.com/lo/cindy
www.sm.com/lo/albert

What I would like to do is translate the ending part to a different URL.
An example would be

www.sm.com/lo/bob would become www.sm/lo.php?name=bob and 
www.sm.com/lo/cindy would become www.sm.com/lo.php?name=cindy

Would Apache ever seek /lo/bob? My understanding from the docs is no but
I would like verification from the gurus.

In addition I would like to have another fake URL, www.sm.com/co and do
the same thing. Can mod_rewrite work with 2 different "fake" URLs and
come up with the proper real URL? Example.

www.sm.com/lo/frank becomes www.sm.com/lo.php?name=frank and
www.sm.com/co/time becomes www.sm.com/co.php?name=time. Would that work
with mod_rewite?

Thank you for your response. If that works my next step is to learn
regular expressions. I have always had a hard time with it but I will
give it another shot as I do realize its importance.

Mike







---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux