You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Stephen Ince <st...@gmail.com> on 2010/06/30 09:32:12 UTC

validation

I have to two regarding struts2 validation
Does struts2 support  actionName-methodName-validation.xml?.
I know struts2 supports actionClass-alias-validation.xml but I am looking for validation on a method within a class.

Is it possible to use xml validation on a collection of objects.
e..g
<input name="elements[i].name" type="text".
I am limited to use ognl field expression for validation.

e.g.

<validator type="expression">
<param name="expression">
elements.{#this.name.length() &gt; 0}.{? #this == false }.size() &lt;= 0
</param>
<message key="elements.name.required" />
</validator>


Any help would be appreciated.

Steve