Main » 2011 » August » 23 » Looping through all request parameters in Java.
12:07 PM Looping through all request parameters in Java. |
Simple few lines of code to loop through a request and print out every parameter and its value.
Enumeration parameterNames = request.getParameterNames();
while (parameterNames.hasMoreElements()){
String requestName = (String)parameterNames.nextElement();
String comment = equest.getParameter(requestName);
System.out.println(requestName);
System.out.println(comment);
}
|
Views: 2959 |
Added by: The_Kat
| Tags: JAVA, getParameterNames, Request
| Rating: 0.0/0 |
|
|
Login form |
|
|
|