var ns = (navigator.appName.indexOf("Netscape") != -1);
var d = document;
function JSFX_FloatDiv(id, sx, sy)
{
        var el=d.getElementById?d.getElementById(id):d.all?d.all[id]:d.layers[id];
        var px = document.layers ? "" : "px";
        window[id + "_obj"] = el;
        if(d.layers)el.style=el;
        el.cx = el.sx = sx;el.cy = el.sy = sy;
        el.sP=function(x,y){this.style.left=x+px;this.style.top=y+px;};
        /* el.sP=function(x,y){this.style.left="50%";this.style.top="50%";}; */

        el.floatIt=function()
        {
              //var obj=getRawObject(this.id);
              var obj=this;
   // window scroll factors
    var scrollX = 0, scrollY = 0;
    if (document.body && typeof document.body.scrollTop != "undefined") {
        scrollX += document.body.scrollLeft;
        scrollY += document.body.scrollTop;
        if (document.body.parentNode && 
            typeof document.body.parentNode.scrollTop != "undefined") {
            scrollX += document.body.parentNode.scrollLeft;
            scrollY += document.body.parentNode.scrollTop
        }
    } else if (typeof window.pageXOffset != "undefined") {
        scrollX += window.pageXOffset;
        scrollY += window.pageYOffset;
    }
    var x = Math.round((getInsideWindowWidth()/2) - (getObjectWidth(obj)/2)) + scrollX;
    var y = Math.round((getInsideWindowHeight()/2) -  (getObjectHeight(obj)/2)) + scrollY;
    shiftTo(obj, x, y);
    show(obj);
        setTimeout(this.id + "_obj.floatIt()", 40);
        }
        return el;
}

