I want to redirect requests to cgi scripts across domain without changing displayed URL on browser. For example:
requested url: http://www.domain1.com/cgi-bin/hello.cgi
new url: http://www.domain2.com/cgi-bin/hello.cgi
The reason behind is a long story. I can tell you later if you want to know. I have success to a certain level. I can redirect requests to a new domain, but it shows a new domain on browser.
RewriteEngine on
RewriteRule ^(.*)/cgi-bin/(.*) http://www.domain2.com/cgi-bin/$2
When I use proxy to hide a new url with the following rule
RewriteEngine on
RewriteRule ^(.*)/cgi-bin/(.*) http://www.domain2.com/cgi-bin/$2 [P]
I saw only plain script, not processed output, on the browser. I enabled proxy server with the following configuration
ProxyRequest on
<Directory proxy:*>
Order allow,deny
Allow all
</Directory>
Anybody can help me with this? All idea are very welcome.
Preliminary test information is as follows:
1) cgi script handler on domain1 and domain2 work ok. I test it by requesting cgi script directly from browser, and it is ok.
2) Proxy works ok. I test it from my browser.
Thanks in advanced.
Nitting.