[jQuery] ajax not working with form validation... help please...

[jQuery] ajax not working with form validation... help please...


i got this error on firebug
data is not defined
submitHandler(form#MyForm1 proccessajax.php)login.php (line 167)
valid()jquery.validate.j... (line 511)
form()jquery.validate.j... (line 374)
(no name)(submit )jquery.validate.j... (line 233)
handle(submit )jquery.js (line 1302)
[Break on this error] data: data,
anyone knows why?
here is the code :
<form method="post" name='MyForm1' id='MyForm1'
action="/remote/proccessajax.php">
<!-- Start MyForm1uemailInputfield -->
<div id="divforMyForm1uemailInputfield">
    <label> uaboutme <em>*</em></label>
    <input name='uemail' type='text' id='MyForm1uemailInputfield' value=''
maxlength='45' />
    <label for="MyForm1uemailInputfield" generated="true"
class="error"></label>
    
    
    
</div>
<!-- End MyForm1uemailInputfield -->
<script type="text/javascript">
$.validator.addMethod("mustvailddate", function(value) { return value ==
"1"; }, 'Invalid date');
$(function() {
    $(".jqcrazillapopupwindow").popupwindow();
    $().ajaxSuccess(function(request, settings){ return true; });
$().ajaxStart(function() {
$.blockUI( '<h1> http://crazilla.linuxlab/images/icons/loading/loading1.gif
<BR> Just a moment...</h1>' ); }).ajaxStop(function() { $.unblockUI(); });
$().ajaxError(function(a, b, e) { throw e; });    $.validator.setDefaults({
debug: false });
    var v = $("#MyForm1").validate({
        
// begin rules ///
rules: { MyForm1uemailInputfield: { minLength: 3, required: true,
maxLength: 45
}}
/////////// end rules ///////////////////
,        focusInvalid: "false",
        event: "keyup",
        submitHandler: function(form) {
            $(form).ajaxSubmit({
                dataType: "json",
                data: data,
                after: function(result) {
                    if (result.status == 0) { v.showErrors(result.data); }
                    if (result.status == 2) { alert(result.data); }
                    if (result.status == 3) { }
                    if( result.status == 1) { alert('done'); } } }); } }); });
</script>
--
View this message in context: http://www.nabble.com/ajax-not-working-with-form-validation...-help-please...-tf3606287s15494.html#a10075505
Sent from the JQuery mailing list archive at Nabble.com.