I am new to jquery. After a lot of trial and errors, I managed to
accomplish what I wanted: beforesubmitting to a form, I check for php
errors and then I display them in a div above the submit button. Works
great. But the problem that I am having, if there are no errors, the
form submits as wanted BUT the next page displays in the div!!!!!

Can someone kindly complete that one line that is missing in below
code? Thank you.


$(document).ready(function() {
    var options = {
        target:        \'#myerror\',
        beforeSubmit:  showRequest,
        success:       showResponse

    };

    $(\'#myformOne\').ajaxForm(options);
});

function showRequest(formData, jqForm, options) {
    var queryString = $.param(formData);
}
function showResponse(responseText, statusText){}

Reply via email to