Question

I need to decode a URL/URI with JSTL so that an encoded string such as:

%3Fname%3DUpHelix

becomes:

?name=UpHelix

I know you can use URLDecoder in regular java but I don't know how to pull it off in JSTL.

Is there a JSTL method that will accomplish this?

Was it helpful?

Solution

There is no standard tag to do that. So you should do it in the controller, or create your own tag that does it and use this tag in the JSP.

This doesn't look like view logic (i.e. markup generation logic) to me, so the best place is probably in the controller.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top