javascript - jQuery Validation Enable Submit Button when Valid - Stack Overflow

I am using jQuery validation on my form and I would like to be able to disable the submit button and ch

I am using jQuery validation on my form and I would like to be able to disable the submit button and change its class, when the form validates. I know I could bind a function on the key up event but I want to know if this is possible from within the jQuery validate framework. I tried doing what this guy suggested, but got nowhere.

I am using jQuery Validate

I am using jQuery validation on my form and I would like to be able to disable the submit button and change its class, when the form validates. I know I could bind a function on the key up event but I want to know if this is possible from within the jQuery validate framework. I tried doing what this guy suggested, but got nowhere.

I am using jQuery Validate

Share Improve this question edited May 23, 2017 at 12:25 CommunityBot 11 silver badge asked Sep 16, 2009 at 21:42 Russ BradberryRuss Bradberry 10.9k17 gold badges73 silver badges85 bronze badges 1
  • Just updated my post.... – RSolberg Commented Sep 16, 2009 at 22:24
Add a ment  | 

1 Answer 1

Reset to default 4

It appears that you may be able to get this to work automatically within the options on the Validate plugin itself.

Check out this link on the jQuery docs for more information.

$("myForm").validate(
   {
       onkeyup: true, 
       onsubmit: false, 
       onclick: true, 
       onfocusout: true
   }
);

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745106730a4611602.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信