JSP Urlencode value

quick and dirty way to use JSP/JSTL to urlencode value:

<c:url var="url" value=""><c:param name="value" value="${param.value}" /></c:url>
<c:import url="http://www.domain.com/?${param.cat}=${fn:substringAfter(url, '=')}" />

Leave a Reply