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.

link|improve this question

40% accept rate
feedback

1 Answer

you can use ProxyPass:

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

here is the apache documentation for more details.

link|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
feedback

Your Answer

 
or
required, but never shown

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