
var ie = document.all&&!window.opera?1:0;
var dom = document.getElementById?1:0;
var ns4 = document.layers?1:0;


function init() {

if(!(ie||dom||ns4)) {
return;
}
else if(ie) {

box = document.all.dropbox.style;
boxheight = document.all.dropbox.offsetHeight+30;
}
else if(dom) {

box = document.getElementById("dropbox").style;
boxheight = document.getElementById("dropbox").offsetHeight+30;
}
else if(ns4) {

box = document.dropbox;
boxheight = box.clip.height;
}

scroll_top=(ie)?document.body.scrollTop:window.pageYOffset;
box.top = scroll_top - boxheight;
speed = 1;
dropIn();
}


function dropIn() {

 speed+=6; 

 if(parseInt(box.top) < scroll_top ) {

  box.top = parseInt(box.top) + speed;
  in_timer = setTimeout("dropIn()", 50);
 } 
 else {
  clearTimeout(in_timer);
 }
}


function dropOut() {

 if(parseInt(box.top) > (-1)*boxheight) {

  box.top = parseInt(box.top)- 40;
  out_timer = setTimeout("dropOut()", 50);
 }
 else {
  clearTimeout(out_timer);
 }
}

window.onload=init;

