I'm still not even certain if that works it will do what you want. Are you trying to mask the address URI so that when a user types, http://www.runeconference.com that's what they see in the address bar instead of http://www.flubb.com/shaun?

Flubber

Born

Posts: 4

3+ Months Ago

Ok let me try and explain it better.

I have 5 parked domains on my NON-Reseller hosting. Its impossible to get them to redirect to certain sub-directories as i have asked the support people many a time.
So i need a script to get the url from the address bar and then redirect to a certain page. So this script would be the index page; and then redirect to a sub-directory containing the website requested in the address bar.

Now i have been talking to the admin of WMT and he says just get reseller to make life easier. And now; i probably will.

RichB

Guru

Posts: 1121

Loc: Boston

3+ Months Ago

REQUEST_URI is only going to hold a forward slash at the topmost directory rather than the whole url. I don't think there is a predefined variable for REQUEST_URL, but perhaps you could make one like this:

hahaha, yeah i know... im just trying to help... maybe for the future use....

pankaj

Born

Posts: 1

3+ Months Ago

I know this is an old topic.Yet this code worked for meYou can test it at your localhost( local apache)When I enter "http://localhost" I am redirected to "site1"And when I enter "http://127.0.0.1" I get redirected to "site2"

This gets useful when you probably use shared hosting on an ecnony package which does not allow you to point your root to a different directory. You can name this as index.php and get going!!Save $2 per month ( as of year 2009) /per domain