[jQuery] Problem wait until function completed???
Hi,
I'have problem with a javascript jquery function like this:
function buttonEffect()
{
$('#button').fadeOut("slow");
$('#button').fadeIn("slow");
alert('Hi');
return;
}
Javascript don't wait until buttonEffect() completion. It shows window
alert 'Hi' before 'fadeIn' and 'fadeOut' start.
What's the problem???
Thanks in advance.