[jQuery] $.ajax on succes is not being executed???
So why doesn't my success callback excutes?
----------------
$(document).ready(function(){
$('.error').hide();
$(".voteBtn").click(function() {
var poll = $("input[@name='poll']:checked").val();
alert("send: "+poll);
if (poll == 'undefined') {
alert("don't post");
$("label#poll_error").show();
return false;
}
var question_id = $("input[@name='question_id']").val();;
var t = $("input[@name='t']").val();
var dataString = 'poll=' + poll +'&question_id='+question_id
+'&t='+t;
alert("send: "+dataString);
$.ajax({
type: "POST",
url: "poll-process3.php",
data: dataString,
success: function() {
alert("why not ");
$("#poll-container").hide();
}
});//end ajax
});//end click/**/
if ($("#poll-results").length > 0 ) {
animateResults();
}
});//end ready
-------------------
all alert are shown except "why not", but poll-process3.php is being
executed.