<!-- ½ºÅ©·Ñ ¹è³Ê ÀÚ¹Ù½ºÅ©¸³Æ® ½ÃÀÛ -->
var bNetscape4plus = (navigator.appName == "Netscape" && navigator.appVersion.substring(0,1) >= "4");
var bExplorer4plus = (navigator.appName == "Microsoft Internet Explorer" && navigator.appVersion.substring(0,1) >= "4");

if(document.all) {
 //IE7 ÀÌÇÏ ¹öÀü¿¡¼­ »ç¿ëµÈ´Ù. Ç¥ÁØÀº getElementById() ÀÌ°í IE6¿¡¼­µµ ÀÌ»ó¾ø´Ù.
 var divObj = document.all['divObj'];  
 var def_top = parseInt(divObj.style.top);
}
else {
 var divObj = document.getElementById('divObj');
 var def_top = parseInt(divObj.style.top);
}

function return_scrollTop() {
 if (document.documentElement && document.documentElement.scrollTop)
  return document.documentElement.scrollTop;
 else if (document.body)
  return document.body.scrollTop;
 else
  return document["divObj"].top;
  
 return 0;
}

function CheckUIElements(){
      var yObjFrom, yObjTo, yMoveFrom, yMoveTo, yOffset, timeoutNextCheck;

      if ( bNetscape4plus ) { 
              yObjFrom   = return_scrollTop();
              yObjTo     = top.pageYOffset + def_top;
      }
      else if ( bExplorer4plus ) {
              yObjFrom   = parseInt(divObj.style.top, 10);
              yObjTo     = return_scrollTop() + def_top;
      }

      timeoutNextCheck = 500;

      if ( Math.abs (yMoveFrom - (yObjTo + 152)) < 6 && yMoveTo < yMoveFrom ) {
              window.setTimeout ("CheckUIElements()", timeoutNextCheck);
              return;
      }

      if ( yMoveFrom != yMoveTo ) {
              yOffset = Math.ceil( Math.abs( yMoveTo - yMoveFrom ) / 10 );
              if ( yMoveTo < yMoveFrom )
                      yOffset = -yOffset;

              if ( bNetscape4plus )
                      divObj.style.top = return_scrollTop() + def_top + yOffset;
              else if ( bExplorer4plus )
                      divObj.style.top = parseInt (divObj.style.top, 10) + yOffset;

              timeoutNextCheck = 10;
      }
      if ( yObjFrom != yObjTo ) {
              yOffset = Math.ceil( Math.abs( yObjTo - yObjFrom ) / 20 );
              if ( yObjTo < yObjFrom )
                      yOffset = -yOffset;

              if ( bNetscape4plus )
                      divObj.style.top = return_scrollTop() + def_top + yOffset;
              else if ( bExplorer4plus )
                      divObj.style.top = parseInt (divObj.style.top, 10) + yOffset;

              timeoutNextCheck = 10;
      }

      window.setTimeout ("CheckUIElements()", timeoutNextCheck);
}

function OnLoad()
{
      var y;
      if ( top.frames.length )
      if ( bNetscape4plus ) {
              divObj.style.top = top.pageYOffset + def_top;
              divObj.style.visibility = "visible";
      }
      else if ( bExplorer4plus ) {

              divObj.style.top = return_scrollTop() + def_top;
              divObj.style.visibility = "visible";
      }
      CheckUIElements();
      return true;
}

OnLoad();
<!-- ½ºÅ©·Ñ ¹è³Ê ½ºÅ©¸³Æ® ³¡ -->

