90
rated 0 times
[
92]
[
2]
/ answers: 1 / hits: 72966
/ 12 Years ago, sun, august 5, 2012, 12:00:00
Possible Duplicate:
Jquery delay execution of script
I am writing a small script that, when the page loads, assigns a CSS subclass to three elements. 800ms later, I want it to remove that subclass.
I thought this code might do it:
<script type=text/javascript>
$(document).ready(function () {
$(#rowone.one).addClass(pageLoad);
$(#rowtwo.three).addClass(pageLoad);
$(#rowthree.two).addClass(pageLoad);
.delay(800);
$(#rowone.one).removeClass(pageLoad);
$(#rowtwo.three).removeClass(pageLoad);
$(#rowthree.two).removeClass(pageLoad);
})
</script>
Sadly it doesn't, any help would be much appreciated. Thanks in advance.
More From » jquery