How can I get the root address from request object?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   neal_ravindran
Posted On:   Monday, April 14, 2003 08:03 PM

How can I get the root address from request object?
Example I could have the address of a page as http://mysite.com/personal/jsp/persData.jsp
I want to get the "http://mysite.com/" part from the request object. Possible via any direct API? I could not find one..but have done this before looong back...Forget how!

Re: How can I get the root address from request object?

Posted By:   Eelco_Cramer  
Posted On:   Tuesday, April 15, 2003 12:11 AM



String theProtocolAndServer = request.getScheme() + "://" + request.getServerName() + "/";

About | Sitemap | Contact