Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to remove the port number.....

 
Yegappan Balasubramanian
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I am using Tomcat 4.0 server to run my JSP application.When i tried to run the application,i have to give the URL like this
http://www.mysite.com:8080/myfolder/myfile.jsp
but actually i want the URL to be given like this
http://www.mysite.com/myfolder/myfile.jsp
Also i dont want to give that http in the URL.
I would like to give the URL like this
www.mysite.com/myfolder/myfile.jsp
Any solution for the above???
Thanks
Yeg
 
Tim Holloway
Saloon Keeper
Pie
Posts: 17989
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That kind of question is more likely to get a fast answer in the Apache/Tomcat forum. However, in answer to your questions:
"http:" is required to tell the server what protocol you will be using. Other common ones are "https:" (secure http) and "ftp:" (file transfer protocol). However, most web browsers will automatically assume/negotiate, so the user typing in a URL can skip that part. It IS however, good practice to include it in hyperlinks and other stuff you send out, as a matter of clarity and to avoid inexplicable errors if the assumption process goes wrong.
Browsers also assume they will be talking to the user's TCP/IP port 80 when using the "http:" protocol. In Tomcat's server.xml file you'll find a way to specify port 80 instead of 8080. 8080 is a popular port for "testing" servers and such, as is 8008.
So actually, if I type in "www.javaranch.com" to by browser's navbar, what is REALLY being processed is "http://www.javaranch.com:80/"
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic