Hey guys, Berk here.
So doing a task system with percent system and so, when you click 'add 10 percents' it should run an ajax request. So it runs but it delays so much, and does not run PNotify.
AJAX code:
I'm not sure what I'm doing wrong?
Thanks.
So doing a task system with percent system and so, when you click 'add 10 percents' it should run an ajax request. So it runs but it delays so much, and does not run PNotify.
AJAX code:
Code:
$(document).ready(function(){
var id = $('#id').text();
$.ajax({
url: 'system/js/tasks/addpercent.php',
method: 'POST',
}).done(function(res) {
new PNotify({
title:'Done',
type:'success',
text:'Success'
});
}).fail(function(res) {
console.log(res);
});
});
Thanks.