Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

How can I have a sub-directory under a domain point to another server, for example loading http://www.xyz.com/myscript/ should load the script located on a different server than xyz.com, this can be achieved via using a sub-domain but I need to avoid that.

xyz.com - loads from server 1

xyz.com/myscript/ - loads from another server 2

I am using Apache.

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

you can use ProxyPass:

ProxyPass /myscript http://server2/myscript
ProxyPassReverse /myscript http://server2/myscript

here is the apache documentation for more details.

share|improve this answer
    
Thanks, will this be SEO friendly and completely transparent to user ? –  iTech Mar 1 '10 at 8:17
    
i can't answer it for seo, but it is transparent to the user. –  Christian Mar 1 '10 at 9:16
    
@itech, yes totally SEO friendly –  Mark Henderson Jul 28 '10 at 5:19
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.