var home_init=0;
var ie=document.all
var dom=document.getElementById
var ns4=document.layers
var bouncelimit=32
var direction="left"
function initbox(){
if (!dom&&!ie&&!ns4)
return
cen=(ie)? document.body.clientWidth/2-250 : (dom)?window.innerWidth/2-250  : window.innerWidth/2-250
crossobj=(dom)?document.getElementById("dropin").style : ie? document.all.dropin : document.dropin
scroll_top=(ie)? document.body.scrollTop : window.pageYOffset
crossobj.top=scroll_top-6000
crossobj.width=505
crossobj.left=cen
crossobj.visibility=(dom||ie)? "visible" : "show"
dropstart=setInterval("dropin()",1)
}
function dropin(){
scroll_top=(ie)? document.body.scrollTop : window.pageYOffset
if (parseInt(crossobj.top)<100+scroll_top)
crossobj.top=parseInt(crossobj.top)+80
else{
clearInterval(dropstart)
bouncestart=setInterval("bouncein()",50)
}
}
function bouncein(){
crossobj.top=parseInt(crossobj.top)-bouncelimit
if (bouncelimit<0)
bouncelimit+=8
bouncelimit=bouncelimit*-1
if (bouncelimit==0){
clearInterval(bouncestart)
}
}
function dismissbox(){
if (window.bouncestart) clearInterval(bouncestart)
crossobj.visibility="hidden"
}
function updateWin(url) {
updateWindow = window.open(url,'update','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width=542,height=145');
}
function openindex(width,height,theurl) {
OpenWindow=window.open(theurl, "newwin", "height="+height+", width=" + width + ",toolbar=no,scrollbars=" + 1 + ",menubar=no,resizable=yes");
self.name="main";
}
function unhidebuttons() {
if (home_init!=0) {
window.clearInterval(home_init);
}
getObj('lbutton1').innerHTML="<div align=right><font size=1 class=formstyle face=arial><a href='javascript:dismissbox()'><font color=#ff6600><b>&nbsp;x</b> cerrar&nbsp;&nbsp;</font></a></font></div>";
}
function doPopup() {
//home_init=window.setInterval('unhidebuttons()',6200);
if (typeof(info)=="undefined") {return};

if (ie) {
document.all.dropin.innerHTML = info;
document.all.dropin.left='250';
}
else if (ns4) {
document.layers['dropin'].document.open();
document.layers['dropin'].document.write(info);
document.layers['dropin'].document.close();
}
else if (dom) {
document.getElementById('dropin').innerHTML= info;
}
initbox();
unhidebuttons();
}