simple $.post isn't working?
I'm pretty new to jQuery so try and go easy....
Trying to do a simple AJAX POST using the jQuery post method and it doesn't seem to be working.
Heres my code:
- $.post("sub-account-ajax.php", { email_address: "test@test.com" },
function(data){
alert("Data Loaded: " + data);
});
Heres the code for sub-account-ajax.php:
- <?php
if (isset($_POST['email_address']))
{
echo 'youre set';
}
else
{
echo 'nothing set';
}
?>
When this code is executed I do not get any alerts or any error messages whatsoever. I've been pretty good with figuring things out so far with jQuery, but this is the first I'm stumped with.