Mario Moura escribió:
Using any validation library, in your HTML example you can bypass the validation using this code:Hi SeVir and FolksMy form have a ajax button. Ajax button always is type="submit" so I tested ValidationAide and Jquery Validation (bassistance.de <http://bassistance.de>)Both plugins have the following bad behavior.When I click in Ajax Button (value="Attach" id="attach-button" name="attach") both think that I am trying send the form and try validate.So My Ajax function cant work :( Can I bypass this? How can I hack this? Ideas?How can I say to "Jquery Validation" to validate id="edit-submit" and not type="submit"? Or how can exclude id="attach-button" from Validation?Because $("#myform").validate(); already declared. My Form is:<form enctype="multipart/form-data" id="myform" method="post" action="/send/invoice"><input type="submit" class="form-submit" value="Attach" id="attach-button" name="attach"/><input type="submit" class="form-submit" value="Submit" id="edit-submit" name="op"/></form> Regards Mario
//inside document.ready
$("#attach-button").click(function(){
$("#myform")[0].submit(); //DOM submit trigger, not jQuery submit
trigger
return false; }); -- Best Regards, José Francisco Rives Lirola <sevir1ATgmail.com> SeViR CW · Computer Design http://www.sevir.orgMurcia - Spain

