I use AJAX to insert data into my table, once this is done however I want my new value to fade in, inplace of the existing .html data.
I have the following only it doesnt seem to fade in…
// UPDATE INCOME
$("#salary-upd").on("submit", function(event) {
event.preventDefault();
var elem = $(this);
$.post("update_salary.php", $(this).serialize(), function(data) {
$(".spends").fadeIn().html(data);
});
Try,