struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Affan Qureshi" <>
Subject Quick Question: rtexprvalue for onclick event in <nested:submit>
Date Thu, 28 Nov 2002 06:42:07 GMT
I want to use a nested bean property in the onclick attribute of the
nested:submit. Since i cannot refer to bean properties in onClick
attributes, I declared a pageContext variable using nested:define. Then I
used that variable in the onclick attribute.

I want to accomplish this:
<nested:submit property="addParametersButton" onclick="updateAchor('<%=
(String)pageContext.getAttribute("attributeId")%>', this.form)">
Add Params

But I get te following error:
[ServletException in:/webpages/editSpecs.jsp]
/webpages/editSpecs.jsp(58,176) jsp.error.attribute.noequal'

I think i cannot give both a <%= %> and a String in the attribute value as I
have done above. But if I remove the String so that my code becomes:
onclick="<%= (String)pageContext.getAttribute("attributeId")%>", it woks
correctly. Is there a work around for this?

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message