I have created a javascript function to make a message fade out in my clients panel.
Here is my function:
- function deletemsg(id)
- {
- $.ajax({ url: "ajax_deletemsg.php?id=" + id, context: document.body, success: function(){
- $('#msg-' + id).fadeOut(1000, function() {
- // Animation complete.
- alert("faded");
- $('#msg-' + id).remove();
- });
- }});
- }
It shows the 'faded' alert message but it doesn't fade the area? How can I fix this?