i'm trying this
function m(){
$('.l').animate({opacity:"0"},1000);
}
$(window).load(m);
but now I want it to do a 3 second delay after the page loads
try with setTimeout()
but does something else
setTimeout(($(window).load(m)), 3000);
try withdelay
$(window).load(m).delay(3000);
also withsleep
function m(){
sleep(3000);
$('.l').animate({opacity:"0"},1000);
}
animate
You would need to indicate the parameter to the functionqueue: false
. According to the documentation:Example: