Use standard jstl for links or they will break
----------------------------------------------
Key: CONTINUUM-783
URL: http://jira.codehaus.org/browse/CONTINUUM-783
Project: Continuum
Issue Type: Bug
Components: Web interface
Reporter: Carlos Sanchez
Fix For: 1.1
I see a lot of links constructed like this
<a
href="${pageContext.request.contextPath}/deleteUser!doDelete.action?accountId=${pageScope.user.accountId}&username=${pageScope.user.username}"><ww:text
name="delete"/></a>
This will break under certain circustancies, like cookies disabled or variables
with some chars that need to be encoded
Also jstl automatically adds the contextPath at the beggining
See http://www-128.ibm.com/developerworks/java/library/j-jstl0318/#N105D3 for
more info
The right way do do it is
<c:url var="deleteUserUrl" value="/deleteUser!doDelete.action">
<c:param name="accountId" value="${user.accountId}"/>
<c:param name="username" value="${user.username}"/>
</c:url>
<a href="<c:out value='${deleteUserUrl}'/>"><ww:text
name="delete"/></a>
when no parameters need to be added it can just be
<a href="<c:url value="/deleteUser!doDelete.action">"><ww:text
name="delete"/></a>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira