Jump to content

jQuery.post code seems legit, but not .post'ing


The Letter E

Recommended Posts

        jQuery('#login_form').submit(function(event){
                alert('submitted');
                event.preventDefault();
                jQuery.post("login", jQuery("#login_form").serialize(), function(data){
                        alert('posted');
                        if( data.status == 1 ){
                                window.location.reload();
                        }else{
                                jQuery('.login_response').html('Incorrect username or password!');
                        }
                }, "json");
        });

 

I've worked with this function before and as I recall this should work fine, and it also conforms with documentation. Perhaps I'm just overlooking some silly little detail. But, any help is appreciated.

 

The script never makes it to the alert('posted'); line.

 

THanks In Advance,

 

E

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.