// JavaScript Document
$(document).ready(function(){
$buildingup = false;
$("#sliders>*").show();
//Blurs all links when clicked
$("a").click(function(){
$(this).blur();
});
$(this).delay(2000,function(){
$("#titlebar").fadeOut(1000);
});
$(this).delay(3500,function(){
//Show the elements
$(".village").stop().animate({top:'30px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$(".cloudbar").stop().animate({top:'0px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$buildingup = true;
});
$("a.toggle").click(function(){
if ($buildingup == false){
$("#titlebar").fadeOut(1000);
$(this).delay(1000,function(){
$(".village").stop().animate({top:'30px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$(".cloudbar").stop().animate({top:'0px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$buildingup = true;
});
}else{
$(".village").stop().animate({top:'366px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$(".cloudbar").stop().animate({top:'-465px'}, {queue:false, duration:2000, easing: 'easeInOutBack'});
$buildingup = false;
$(this).delay(2000,function(){
$("#titlebar").fadeIn(1000);
});
}
});
});
Asked
Active
Viewed 1,043 times
-1
-
none of it. the titlebar div is supposed to fade out and then the village and cloudbar begin their animation but this does not work wen i use 1.6.2 – Derek Aug 01 '11 at 23:35
-
For one, `delay` is not to be used as a replacement for `setTimeout`. This is a fairly simple substitution to make. http://api.jquery.com/delay – Jeremy Roman Aug 02 '11 at 00:18
-
are you able to give a live example of it not working? Just looking at this code isn't particularly useful. – Alastair Pitts Aug 02 '11 at 00:18
-
Have you even tried debugging your own code? Are there any errors? – Ben Rowe Aug 02 '11 at 00:24
-
Why don't you make a jsFiddle? – Steve Wellens Aug 02 '11 at 00:49
1 Answers
0
The differences between 1.3.2 are listed here: http://jquery14.com/day-01/jquery-14
And the release notes for 1.5: http://blog.jquery.com/2011/01/31/jquery-15-released/
The 1.4 link has a list of breaking changes, including a link to this plugin to counteract the breaking changes.
And now 1.6 as well: http://blog.jquery.com/2011/05/03/jquery-16-released/

Community
- 1
- 1

braindamage
- 2,226
- 4
- 24
- 33