Forum Moderators: phranque
We have a website that's running a java application (on an enhydra Java application server, not through Apache. This cannot be changed). This Java app runs on a separate port from Apache (port 81), and is only accessible through its IP address.
We have dedicated hosting
What I want to do is have a folder or sub domain on our main domain rewrite to the java applications address..
So http://example.com/javaapp really points to 111.22.33.44:81..
Is this possible through .htaccess? Or do I need to change something in the Apache configuration?
Any help would be greatly appreciated.
Thanks
[edited by: jdMorgan at 3:58 pm (utc) on Aug. 28, 2008]
[edit reason] example.com & hosting specifics [/edit]
<IfModule mod_proxy.c>
ProxyRequests On
ProxyPreserveHost On
ProxyStatus On
<Location /status>
SetHandler server-status
Order Deny,Allow
Deny from all
Allow from 127.0.0.1
</Location>
ProxyPassReverse /intranet [localhost:81...]
ProxyPass /intranet [localhost:81...]
</IfModule>
Now it forwards from http://example.com/intranet to http://example.com:81
However I want the address bar to just stay at http://example.com/intranet
What am I doing wrong?
I don't think that would cause the address bar to change, so look for mod_alias, mod_rewrite, or scripted redirects -- Only a redirect is going to send a response to the browser and make it change its address bar.
Jim
<IfModule mod_proxy.c>
ProxyRequests On
ProxyPreserveHost On
ProxyStatus On
<Location /intranet>
SetHandler server-status
Order Deny,Allow
Deny from none
Allow from all
</Location>
ProxyPassReverse /intranet [localhost:81...]
</IfModule>
Now when I go to example.com/intranet it jumps to an Apache status page?
ProxyStatus On
<Proxy *>
Order Deny,Allow
Allow from all
</Proxy>
ProxyPassReverse / [localhost:81...]
<Location /intranet>
Order allow,deny
Allow from all
</Location>
However when I go to example.com/intranet I get:
Not Found
The requested document was not found on this server.