Solved

Regarding the deprecated javax.servlet.http.HttpUtils class

Posted on 2003-11-19
4
430 Views
Last Modified: 2008-03-10
The API docs say:

javax.servlet.http.HttpUtils
Deprecated. As of Java(tm) Servlet API 2.3. These methods were only useful with the default encoding and have been moved to the request interfaces.

I am pretty sure there's nothing in the HttpServletRequest interface, nor in the ServletRequest.

Am I wrong? How can you _parse_ the query string? (I use 1.4.0 SE & 1.3.0 EE)

0
Comment
Question by:piou
  • 3
4 Comments
 
LVL 35

Expert Comment

by:girionis
ID: 9777220
>  How can you _parse_ the query string?

  Use request.getParameter("parameter");
0
 
LVL 35

Expert Comment

by:girionis
ID: 9777232
 If you are talking about getting the whole query use:

  request.getQueryString();

  or an Enumeration to get all the parameters:

  Enumeraiton enum = request.getParameterNames();
0
 

Author Comment

by:piou
ID: 9777487
Oh! I thought the getParameter() was only for form data included in the response. You say that the same method parses the query string?!
0
 
LVL 35

Accepted Solution

by:
girionis earned 50 total points
ID: 9777504
 This method is used to get any parameters in the request, whether it is in a form (POST/GET) or explicitly in a URL (GET).
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
What is the latest versions eclipse neon 2 139
stackato and cloud 4 69
diffSum example 4 24
javap bin 2 27
Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now