Reputation: 1828
I tried to send value of id-property via link as
<html:link action="action?method=view&newsID='<bean:write name="news" property="id"/>'">View</html:link>
or
<input type="hidden" name="newsID" value='<bean:write name="news" property="id"/>'/>
<html:link
action="action?method=view&newsID=${newsID}">
View
</html:link>
But nothing work. Can you help me?
Upvotes: 0
Views: 3016
Reputation: 691645
Do yourself a favor, and use the JSTL:
<c:url var="theUrl" value="/action.do">
<c:param name="method" value="view"/>
<c:param name="newsID" value="${news.id}"/>
</c:url>
<a href="${fn:escapeXml(theUrl)}">View</a>
Upvotes: 4