Replace ajaxForm with ajaxSubmit. ajaxForm binds a submit event, just
like validate.

Jörn

On Sun, Mar 1, 2009 at 6:45 AM, mehodgson <mehodg...@gmail.com> wrote:
>
> I have an ajax form in a CakePHP based website that I am trying to
> validate using the the jquery validation plugin. Every thing seems to
> work just fine on the validation portion, but even when all the fields
> are valid the form fails to submit. The weird part is that after the
> form is valid and the submit button clicked to no effect, it will
> submit if I go and delete the data from a required field and then
> click submit again (when the form should not be valid).
>
> Here is my code for the validation:
>
> <script type="text/javascript">
> $(document).ready(function() {
>        $('#SignUpForm').validate({
>           debug: false,
>           onfocusout: false,
>           onkeyup: false,
>           submitHandler: function(form) {
>                $(form).ajaxForm(function(data) {
>                    $('#signUpBox').html(data);
>                });
>            },
>        });
>
> });
> </script>
>
> Anyone have any ideas on how to fix this?
>

Reply via email to