You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Ben <ne...@gmail.com> on 2005/11/10 08:13:38 UTC

Validate url

Hi

I followed the Struts User's Guide to setup the form so that it
validates the URL when the user submits the form. I use the following
validation settings for the URL field.

    <field property="url" depends="url">
        <arg0 key="company.url"/>
        <var>
           <var-name>schemes</var-name>
           <var-value>http,https</var-value>
        </var>
    </field>

No matter what I put in the field, it always return false, here are
some of the urls I used:

http://www.yahoo.com/
http://localhost/
https://www.amazon.com/exec/dsfasdf

Please let me know how to use Struts url validation.

Thanks,
Ben

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org