How can I get the full URL with the attached parameters?
1 Answer(s)      8 years ago
Posted in : JSP-Servlet


View Answers

March 27, 2009 at 1:12 AM

Hi Friend,

You can try the following code to solve your problem. Here we can use combination of getRequestURL() method and getQueryString() method to achieve requirement.

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>JSP Page</title>

String str=request.getRequestURL()+"?"+request.getQueryString();

RoseIndia Team