fadeIn & fadeOut not working in IE8 or lower

fadeIn & fadeOut not working in IE8 or lower

Hi all,


I have a problem with my jquery. The next code works fine in IE9, FF and Chrome, but not in IE8 or lower. The problem is that my fade out and fade in on a block element are not working. The problem in action can be found here:  http://www.paarsekever.nl/Showroommodellen.html and soem snippets of the code:
HTML:
<div id=" linkgoleft">goleft</div>
<div class="infoBlock block0" >data</div>
<div class="infoBlock block1" >data</div>
<div class="infoBlock block2" >data</div>
<div id=" linkgoright">goright</div>


CSS:
     display none ;
     position relative ;
     top 0 ;
}
.block0 {
     display block ;
} /* note no .block1 or .block2 */


JQUERY:
  1.  $(document).ready(function() { 
     // do stuff when DOM is ready 
    var num = 0; 
    var maxNum = $('.infoBlock').length-1; 
    if (num == 0) $('#linkgoleft').hide(); 
    if (num == maxNum) $('#linkgoright').hide(); 

    $('#linkgoright').click(function() { 
    if (num < maxNum) { 
    $('#linkgoleft').show(); 
    num++; if (num == maxNum) $(this).hide(); 
    // prepare next block var cb = '.block'+(num-1); 
    var nb = '.block'+num; 
    //alert('test'); 
    $(nb).css('left', '860px'); 
    //$(nb).css('display', 'block'); 
    $(cb).animate({left:'-860px'}, {queue: false, duration: 600}, function() { }); 
    $(cb).fadeOut(600); 
    $(nb).animate({left:'0px'}, {queue: false, duration: 600}, function() { }); 
    $(nb).fadeIn(600); 
    }); 

    $('#linkgoleft').click(function() { 
    if (num > 0) { 
    $('#linkgoright').show(); 
    num--; 
    if (num == 0) $(this).hide(); 
    // prepare next block 
    var cb = '.block'+(num+1); 
    var nb = '.block'+num; 
    $(nb).css('left', '-860px'); 
    $(cb).animate({left:'860px'}, {queue: false, duration: 600}, function() { }); 
    $(cb).fadeOut(600); 
    $(nb).animate({left:'0px'}, {queue: false, duration: 600}, function() { }); 
    $(nb).fadeIn(600); 
    }); 
     }); 
What could be the problem? Best regards, Geert
    • Topic Participants

    • info