logic:messagesPresent ?

-----Original Message-----
From: Christoph Kutzinski [mailto:[EMAIL PROTECTED]
Sent: 23 March 2004 17:51
To: Struts Users Mailing List
Subject: Displaying Content only if form errors are present


Hi,

I'm trying to display a piece of HTML only if the previous form submit 
create an ActionError. This is what I got so far:

<logic:present name="<%=org.apache.struts.Globals.ERROR_KEY%>">
     <td class="error"><html:errors property="company" /></td>
</logic:present>
<td>Company:</td><td><html:text property="company"/></td>

this works, but seems not the "cleanest" way to do this to me.
Does anyone know a better way, e.g. a custom tag for this.
BTW I tried this with JSTL core, too, but couldn't get it to work:

<c:if test="${!empty $org.apache.struts.action.ERROR}">

evaluates always to false.
Does anyone know how to get this to work with JSTL?


thanks in advance,

Christoph

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

This e-mail and any attachment is for authorised use by the intended recipient(s) 
only. It may contain proprietary material, confidential information and/or be subject 
to legal privilege. It should not be copied, disclosed to, retained or used by, any 
other party. If you are not an intended recipient then please promptly delete this 
e-mail and any attachment and all copies and inform the sender. Thank you.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to