$(document).ready(function(){
    window.onscroll = function(){
        var forum_main = document.getElementById("forum_main");
        var thetop =document.documentElement.scrollTop + document.body.scrollTop;
        var forum_box_top = forum_main.offsetTop;
        //window.console && console.log(forum_box_top);
        //window.console && console.log(thetop);
        if(thetop >= forum_box_top){
            $('#forum_float_box').addClass('twfir');
        }else{
            $('#forum_float_box').removeClass('twfir');
        }
    }
})