I am developing a java web application using eclipse and tomcat server.
Application consists of JSPs and servlets.
I have deployed the application on tomcat server and I am redirecting to this application from the domain name.
When I goto “mydomain.co.uk” it redirects to the application with the URL “server:port/app_name”.
I don’t want people to see the serverIP and the port.
How can I show a different URL instead of “server:port/app_name”.
Or is there anyway to make the URL constant for every JSP.
Application should work as it is working now but should show a different URL.
I am developing a java web application using eclipse and tomcat server. Application consists
Share
If the protocol is http:// and the port number is not “80”, then the port must be displayed in the URL (the same is true for https:// and port 443). If you don’t want /app_name in your URL then you either have to re-name your webapp to ROOT (or ROOT.war if you are using a WAR file) or have a reverse proxy out front that can re-write the URLs. If you use a reverse proxy, you’ll need to configure it and Tomcat properly so that both work to produce correct externally-facing URLs.