Hi everyone, 
can someone confirm whether in struts's validator
(which if i'm not mistaken, rely on commons-validator), 
we can or we can not
use non-standard bundle (i.e ApplicationResources.properties)?
If not, what's the usual workaround that you do?


I've tried using Struts 1.2, downloaded from
http://www.apache.org/~martinc/struts/v1.2.0/

and modify the "struts-example" web-apps in validation.xml
so the "username" property will be from "alternate" bundle
where that "alternate" bundle is already defined in 
struts-config.xml
as follow:
  <message-resources
    parameter="org.apache.struts.webapp.example.AlternateApplicationResources"
    key="alternate">
  </message-resources>


validation.xml
        <form name="RegistrationForm">

            <field property="replyToAddress"
                    depends="email">
                <arg0   key="prompt.replyToAddress"/>
            </field>

            <field property="username"
                    depends="required">
              <arg bundle="alternate" key="prompt.username" position="0"/>
            </field>

        </form>


Lots of thanks for any suggestion/helps.

~dion

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

Reply via email to