Hi, I can't seem to imaging how I would try to filter HTML tags through servlet filters. I know that I could get all the parameters through response.getParameterNames(), but how am I suppose to send the filtered names to the servlet request again? I guess I better let my code speak for me...
Sorry, I couldn't find any other way to explain the problem. I hope you understand. Thanks!
posted 9 years ago
You can't alter the request parameters, just read them. If you could there would be a setParameter() method. You save the altered values as the request attributes and use your saved request attributes in your servlet.Parameters and attributes do not share a name space so a parameter named "name" and an attribute keyed "name" are distinct.