Java not adding classes on IE9/8
I'm working on this website
The problem is that on IE9/8 the classes that are added/removed are not
working.
For example, after the page is loaded the body get's the .open class on
chrome/mozilla but on IE9/8 it still has the .close class, that happens
with all the animations so the page basically doesn't work on those
browsers.
This is the code of the body load:
/****************
* GLOBAL BINDS *
****************/
$(window).bind({
'load' : init,
'resize' : resizing,
'resizeEnd' : resize_end
})
function init(){
var open_time = false;
var open_load = false;
$('#home_img img').each(function(){
$(this).bind({
'load' : function(){
if(open_time){
this.open_stage()
}
open_load = true;
}
}).each(function(){
if(this.complete) jQuery(this).trigger("load");
});
})
var first_open = setTimeout(function(){
open_time = true;
if(open_load){
this.open_stage()
}
}, 2000);
this.open_stage = function(){
$('body').removeClass('close');
$('body').addClass('open');
$('#menu').addClass('active');
}
background_positions();
center_image($('#home_img > img'));
remove_blinder();
}
function resizing(){
center_image($('#home_img > img'));
background_positions()
position_section_items()
position_section_paginate();
if(this.resizeTO) clearTimeout(this.resizeTO);
this.resizeTO = setTimeout(function() {
$(this).trigger('resizeEnd');
}, 500);
}
function resize_end(){
position_section_items()
position_section_paginate();
}
Any idea what is the problem, it has never happened to me before, maybe on
IE8 but not on IE9. Also the page gives no errors... so I have no clue.
No comments:
Post a Comment