Apache: Use requested directory as a parameter
Posted
by
friendlycello
on Server Fault
See other posts from Server Fault
or by friendlycello
Published on 2012-10-03T21:36:35Z
Indexed on
2012/10/03
21:41 UTC
Read the original article
Hit count: 172
Here's what I'd like to do:
If a user goes to www.example.com/thislocation
, I'd like to redirect to a particular script and give it "thislocation" as a parameter.
So if a user navigated to www.example.com/thislocation
, I'd like to redirect to www.example.com/cgi-bin/test.pl?parameter=thislocation
, and similarily, if the user navigated to www.example.com/thatlocation
, I'd like to redirect to www.example.com/cgi-bin/test.pl?parameter=thatlocation
.
Is this possible with Apache?
© Server Fault or respective owner