Changes between Version 5 and Version 6 of ZooWebSite/2015/Scripts/Welcome
- Timestamp:
- Dec 3, 2015, 4:06:45 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ZooWebSite/2015/Scripts/Welcome
v5 v6 27 27 28 28 $(window).load(function(){ 29 $('.topr').prepend('<li><a id="volb" class="vc hello" href="#" data-toggle="tooltip" data-placement="left" title="Toogle music"><i class="glyphicon glyphicon-volume-off"></i></a></li>'); 30 $('#volb').tooltip(); 31 $( ".ct" ).animate({opacity: 1}, 5000, function() {$(".bird").show();birdSound.play();}); 29 $( ".ct" ).animate({opacity: 1}, 3000, function() {$(".bird").show();}); 32 30 var birdSound = document.getElementById('birdsound'); 33 31 var birdTxt=document.getElementById('birdc'); … … 36 34 return false; 37 35 }; 38 39 function toggleSound() {40 var audioElem = document.getElementById('africasound');41 if (audioElem.paused) {42 audioElem.play();43 //$('#africasound').volume=0.3;44 $('#volb').html('<i class="glyphicon glyphicon-volume-up"></i>')45 } else {46 audioElem.pause();47 $('#volb').html('<i class="glyphicon glyphicon-volume-down"></i>');48 }49 $("#africasound").bind('ended', function(){50 $('#volb').html('<i class="glyphicon glyphicon-volume-down"></i>')51 });52 }53 54 $("#volb").click(function() {55 toggleSound();56 });57 36 58 37 });