Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Feb 2013
    Posts
    31
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Why does this Jquery code not work with IE.

    Hi, i need help with this jquery code. It is not working in IE. Ive tested it on the latest version. It works in both FireFox and Chrome however.

    http://jsfiddle.net/3JKkj/47/


    Code:
    $(document).ready(function() {
    	showHeadingAndIcon();
    })
    
    var heading_cur=0;
    var icon_cur=0;
    function showHeadingAndIcon(){
    	$('#heading'+(heading_cur+1)).css({opacity: 0}).animate({opacity: 1.0,left: "50px"}, 1000);
        $('#Icon'+(icon_cur+1)).css({opacity: 0}).animate({opacity: 1.0,right: "50px"}, 1000);
    	setTimeout(hideHeadingandIcon, 5000);
    }
    function hideHeadingandIcon(){
    	$('#heading'+(heading_cur+1)).css({opacity: 1}).animate({opacity: 0,left: "-50px"}, 1000);
    	heading_cur=(heading_cur+1)%4;
        $('#Icon'+(icon_cur+1)).css({opacity: 1}).animate({opacity: 0,right: "-50px"}, 1000,function(){showHeadingAndIcon();});
    	icon_cur=(icon_cur+1)%4;
    }

  • #2
    New Coder
    Join Date
    Feb 2013
    Posts
    31
    Thanks
    2
    Thanked 0 Times in 0 Posts
    bump!


  •  

    Tags for this Thread

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •