I have a post method as shown below:
$(".buttons").click(function(){
var gettopic=$.post("topic.php", {id: topicId}, function(result){
});
})
I tried to interrupt the old recording when I pressed a new button: So I'm tired
$(".buttons").click(function(){
if (gettopic) {
gettopic.abort();
}
var gettopic=$.post("topic.php", {id: topicId}, function(result){
});
})
However, this does not work. So I thought, how can this be fixed?
source
share