The tag attribute value must be one big <%= %> or static text. You can't mix static text and a <%= %>. This is a limitation of JSP, and not something strange with Struts JSP tags in particular. Fortunately, it is pretty easy to create a <%= %> expression that will have the value you want.
Instead of: <html:select property ="exception" onClick="java script:showOtherExceptions('<%= ELSEnquiryConstantsIF.EXCEPTION %>');" /> You can write it like this (all in one big <%= %> expression): <html:select property ="exception" onClick='<%= "javascript:showOtherExceptions('" + ELSEnquiryConstantsIF.EXCEPTION + "');" %>' /> Or something like this: <% String myOnClick = ( "javascript:showOtherExceptions('" + ELSEnquiryConstantsIF.EXCEPTION + "');" ); %> <html:select property ="exception" onClick="<%=myOnClick%>" /> -Max ----- Original Message ----- From: "vasudevrao gupta" <[EMAIL PROTECTED]> To: "'Struts Users Mailing List'" <[EMAIL PROTECTED]> Sent: Sunday, January 25, 2004 12:17 AM Subject: Problem with <%= ... %> inside struts tags > > Hi All, > > I have the following code in my JSP file, and I am using the STRUTS > framework. > code: > <html:select property ="exception" onClick="java > script:showOtherExceptions('<%= ELSEnquiryConstantsIF.EXCEPTION %>');" > /> > where showOtherExceptions is a javascript function I have > already written. > The problem is that this doesn't work as expected. The part that > should be filled with "ELSEnquiryConstantsIF.EXCEPTION" stays as > "ELSEnquiryConstantsIF.EXCEPTION" in the final HTML output.. > When I view source on the outputted HTML page, the html:submit > tag converts to the following: > code: > <input type="select" name ="exceptione" onClick="java > script:showOtherExceptions('<%= ELSEnquiryConstantsIF.EXCEPTION %>');" > /> > > Please help > > Regards > VasudevRaoGupta > > > Confidentiality Notice > > The information contained in this electronic message and any attachments to this message are intended > for the exclusive use of the addressee(s) and may contain confidential or privileged information. If > you are not the intended recipient, please notify the sender at Wipro or [EMAIL PROTECTED] immediately > and destroy all copies of this message and any attachments. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]