This project is archived and is in readonly mode.

#213 ✓resolved
Jean Rumeau

problem Integrating Form.Validator on Form.Request

Reported by Jean Rumeau | December 15th, 2009 @ 02:26 AM | in 1.2.4.3

Hello, im trying to integrate Form.Validator on Form.Request as i read on the documentation.

This is the code im using:

new Form.Validator( $('formCrearNivel') );
new Form.Request.Append( $('formCrearNivel'), $('update') );

i have the validators on the class of the elment inputs like:

<input type="text" size="7" name="id_nivel" id="id_nivel" class="required alphanum" />

But when i submit the form, it shows an error on firebug:

fv is not defined
[Break on this error] if (valid || !fv.options.stopOnFailure) {\r\n

Event when a new class is added to the element "validation-failed", so i suppose validation part is working fine, but the submit event isnt stoping, even using "stopOnFailure: true".

I checked the code on the line of error and it seems that var fv defined on Form.Request.attach() is not beeing passed to Form.Request.onFormValidate().

I hack the code using defining this.fv instead of var fv and works fine, but thats not the idea, i need help to know if im using the classes in the wrong way or confirm this as a bug in order to submit a ticket for it.

Thanks.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

The MooTools Extensions

People watching this ticket

Pages