The moose likes Servlets and the fly likes Extracting Query String from URL Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Extracting Query String from URL" Watch "Extracting Query String from URL" New topic

Extracting Query String from URL

Satyajeet Kadam
Ranch Hand

Joined: Oct 19, 2006
Posts: 215
Q1) My request URL is url: http://localhost:8080/Json/register?action:getReservations. On server side i want to extract string getReservations which is my name of my method in a servlet.To acheive i am writing servlet code

it return me as

How can i get only getReservations String ?
Madhan Sundararajan Devaki
Ranch Hand

Joined: Mar 18, 2011
Posts: 312

Please use the Servlet API, HttpServletRequest.getParameterValues.

Not many get the right opportunity !
I agree. Here's the link: http://aspose.com/file-tools
subject: Extracting Query String from URL
Similar Threads
If QueryString has # value in one of the prameter then how to get the complete URL from request
Pass request parameters to getRequestDispatcher()
doubt about javabeat mock exam
getRequestURI() returns query parameters for path="/submit.do?my=Update" in WebSphere 5.1
How to specify a query string in servlet mapping?