浮动层-JS兼容IE6

//引用jquery 包
/*
orderBycat 与 orderBycatHead 双层浮动*/ $(window).scroll(function () { var top = $(window).scrollTop(); var topDiff = top; if (top >= 350) { if ($.browser.msie && ($.browser.version == "6.0")) { $("#orderBycat").addClass("rightFloatRight"); $("#orderBycatHead").addClass("rightFloatRight"); //预定菜单车 document.getElementById("orderBycat").style.top = topDiff;//菜单栏 document.getElementById("orderBycatHead").style.top = topDiff;

       /*如果固定在大层中,则不需要用 下列定位*/
       document.getElementById("orderBycatHead").style.left = "99px";
       document.getElementById("orderBycat").style.right = "247px"; }
else { $("#orderBycat").addClass("fix_top"); $("#orderBycatHead").addClass("fix_top"); } } else { $("#orderBycat").removeClass("fix_top"); $("#orderBycat").removeClass("rightFloatRight"); $("#orderBycatHead").removeClass("fix_top"); $("#orderBycatHead").removeClass("rightFloatRight"); } });

/*去除IE下抖动*/
*html{background-image:url(about:blank);background-attachment:fixed;}

/*浮动*/
.rightFloatRight {
    position: absolute;
    top: 0;
    /*_position:absolute;
    left:80px;*/
    /*_top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight)-610+"px");*/
}
.fix_top {
    bottom: auto;
    position: fixed;
    top: 0;
    z-index: 10000;
    /*_position:absolute;
    _left:500px;
    _top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight)-450+"px");*/
}