struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Benedict" <pbened...@apache.org>
Subject Re: S1-1.3.8 Validation using 'validwhen' for radio button
Date Sat, 11 Aug 2007 08:40:39 GMT
I do not believe validwhen generates Javascript validation. It is only on
the server-side.

On 8/10/07, Vivek Chauhan <simplevivek@gmail.com> wrote:
>
>
> Hi,
>
> I am trying to do a conditional validation using 'validwhen'.
> There is group of two radio buttons (values 'Yes' and 'No') and on
> selecting
> any one of them either a drop down box is displayed or a text box is
> displayed.
>
> I want to validate the text box or drop down box based on which radio
> button
> is selected
>
> I have added the following entry in validation.xml:
>         <form name="productForm">
>                 <field property="someStatus" depends="required">
> <!-- This is the radio button with two options Yes and No -->
>                                 <arg key="label.status" />
>                 </field>
>
>                 <field property="statusText" depends="validwhen">
>                         <arg position="0" key="label.text.value" />
>                         <var>
>                                 <var-name>test</var-name>
>                                 <var-value>
>                                         ((someStatus != 'Yes') or (*this*
> != null))
>                                 </var-value>
>                         </var>
>                 </field>
>         </form>
>
> The javascript validation is not generated for this case.
>
> Similar questions remain unanswered on this mailing list
>
> Thanks
> --
> View this message in context:
> http://www.nabble.com/S1-1.3.8-Validation-using-%27validwhen%27-for-radio-button-tf4248440.html#a12090493
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message