.js in Validator Framework

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

.js in Validator Framework

debussy007
Hi ,

I'm using the Validator framework in my Struts application.

All I do is moving commons-validator-1.3.1.jar in the lib folder of my web
application.
I can see also that there are other files, commons-validator-1.3.1.js and
commons-validator-1.3.1-compress.js.

What are they for ? Where can I find resources about them ?

Thank u !
Reply | Threaded
Open this post in threaded view
|

Re: .js in Validator Framework

Niall Pemberton
The two files you refer to are the "full" javascript routines - so
that you can include them as a link in the <script> element of your
page, rather than the "static" javascript routines being rendered
in-line in your page

<script type="text/javascript" language="JavaScript"
    src="/commons-validator-1.3.1-compress.js."></script>

The two versions are compressed (using the Dojo/Rhino javascript
compressor) and un-compressed.

As well as these there are also now compressed versions of the
individual scripts including in the commons validator jar. In order to
these you need a validator-rules.xml which is configured for the
compressed versions. The next release of Struts will ship with an
addtional "compressed" validator-rules.xml so people can plug in
either version.

So you either need to update your validator rules in the following way:
    http://tinyurl.com/yetjz7

Or grab the one from the Struts subversion repository
    http://tinyurl.com/ybqffk

Besides that there isn't much more information, the issue ticket is here:
   http://issues.apache.org/jira/browse/VALIDATOR-142

Info on the Dojo/Rhino compressor:
   http://dojotoolkit.org/docs/compressor_system.html

Niall

On 12/9/06, Thomas Thomas <[hidden email]> wrote:

> Hi ,
>
> I'm using the Validator framework in my Struts application.
>
> All I do is moving commons-validator-1.3.1.jar in the lib folder of my web
> application.
> I can see also that there are other files, commons-validator-1.3.1.js and
> commons-validator-1.3.1-compress.js.
>
> What are they for ? Where can I find resources about them ?
>
> Thank u !

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: .js in Validator Framework

debussy007
Thank you for the information !