We help IT Professionals succeed at work.
Get Started

Redirect to different folder, depening on domain name?

Last Modified: 2012-05-09
Hello all,

Im not sure what im really asking for but. If i have a webserver with ip address: and on this i want multple sites hosted. Depending on the domain name can i redirect it to a different folder? or say "look in this folder, for this domain name". If you know what i mean? I think there may be some kind of .htaccess things i can do?

i haz..

http://www.example1.com ->
http://www.example2.com ->
http://www.example3.com ->

All pointing to the same thing, but 3 totally different websites all located in different folders, how can it be pointed to a specific folder?

I hope i make sense:)



edit: the above obviously is an example, 3 is not an exact figure im just looking for a way to do the redirect or point to this folder based on the URL, if even possible
Watch Question
This problem has been solved!
Unlock 1 Answer and 4 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE