I want to type
http://example.com
and access
http://example.com:8080
but I want the browser address bar still displays
http://example.com
Is it possible to do that only using the .htaccess file?
I want to type
http://example.com
and access
http://example.com:8080
but I want the browser address bar still displays
http://example.com
Is it possible to do that only using the .htaccess file?
There is an answer to another question on stackoverflow that is similar but different. You should be able to do something like this in your htaccess file:
RewriteEngine On
RewriteRule ^/(.*)$ http://example.com:8080/$1 [L,P]
ProxyPassReverse / http://example.com:8080/
This will take incoming requests and rewrite them on the Apache server and return the response from the other server internally.
In .htaccess file:
RewriteEngine On
RewriteRule (.*) http://example.com:8080/$1 [P]
Works for me.