    function preloadImages() {
        var d=document;
        if(d.images)
        {
            d.preloaded = new Array();
            var i,j=d.preloaded.length,a=preloadImages.arguments;
            for(i=0; i<a.length; i++)
                if (a[i].indexOf("#")!=0)
                {
                    d.preloaded[j]=new Image;
                    d.preloaded[j++].src=a[i];
                }
        }
    }
    
    function size() {
        var myHeight = 0;
        var myWidth = 0;
        var add = 0;
        if( typeof( window.innerWidth ) == 'number' ) {
            //Non-IE
            myHeight = window.innerHeight;
            myWidth = window.innerWidth;
        } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
            //IE 6+ in 'standards compliant mode'
            myHeight = document.documentElement.clientHeight;
            myWidth = document.documentElement.clientWidth;
        } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
            //IE 4 compatible
            myHeight = document.body.clientHeight;
            myWidth = document.body.clientWidth;
        }
        
        if (myWidth<999) {
            var scrOfX = 0
            if( typeof( window.pageYOffset ) == 'number' ) {
            //Netscape compliant
                scrOfX = window.pageXOffset;
            } else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) {
                //DOM compliant
                scrOfX = document.body.scrollLeft;
            } else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) {
                //IE6 standards compliant mode
                scrOfX = document.documentElement.scrollLeft;
            }
            add = myHeight - 54 - 31 - 5 - 1 - 30 + scrOfX;
        } else {
            add = myHeight - 54 - 31 - 5 - 1 - 30;
        }
        return add;
    }
