function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function writeCookie(name, data, noDays){
  var cookieStr = name + "="+ data
  if (writeCookie.arguments.length > 2){
    cookieStr += "; expires=" + getCookieExpireDate(noDays)
    }
  document.cookie = cookieStr
}

function readCookie(cookieName){
   var searchName = cookieName + "="
   var cookies = document.cookie
   var start = cookies.indexOf(cookieName)
   if (start == -1){ // cookie not found
     return ""
     }
   start += searchName.length //start of the cookie data
   var end = cookies.indexOf(";", start)
   if (end == -1){
     end = cookies.length
     }
   return cookies.substring(start, end)
}

function blocking(nr, cookie, vis_state)
{
        if (document.layers)
        {
                current = (document.layers[nr].display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, current);
                document.layers[nr].display = current;
        }
        else if (document.all)
        {
                current = (document.all[nr].style.display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, current);
                document.all[nr].style.display = current;
        }
        else if (document.getElementById)
        {
                display = (document.getElementById(nr).style.display == 'none') ? vis_state : 'none';
                if (cookie != '')
                        writeCookie(nr, display);
                document.getElementById(nr).style.display = display;
        }
}


function adjust_popup()
{
        var w, h, fixedW, fixedH, diffW, diffH;

        if (document.all) {
                fixedW = document.body.clientWidth;
                fixedH = document.body.clientHeight;
                window.resizeTo(fixedW, fixedH);
                diffW = fixedW - document.body.clientWidth;
                diffH = fixedH - document.body.clientHeight;
        } else {
                fixedW = window.innerWidth;
                fixedH = window.innerHeight;
                window.resizeTo(fixedW, fixedH);
                diffW = fixedW - window.innerWidth;
                diffH = fixedH - window.innerHeight;
        }
        w = fixedW + diffW;
        h = fixedH + diffH;
        if (h >= screen.availHeight) w += 16;
        if (w >= screen.availWidth)  h += 16;
        w = Math.min(w,screen.availWidth);
        h = Math.min(h,screen.availHeight);
        window.resizeTo(w,h);
        window.moveTo((screen.availWidth-w)/2, (screen.availHeight-h)/2);
}


var txt0="Welcome to your new Addiction.";
var txt1=" 81-09 2nd Floor Roosevelt Ave. Jackson Heights NY 11372";
var txt2=txt0+txt1+"                                                         ";
var wait=100;
var refresco=null;


function rotulo_izquierda() {
        window.status=txt2;
        txt2=txt2.substring(1,txt2.length)+txt2.charAt(0);        
        refresco=setTimeout("rotulo_izquierda()",wait);
        }



TotalNumerOfURLs = 5;
function MakeArray(n) {

   this.length = n;
   for (var i = 1; i <= n; i++) { 
     this[i] = 0 }
     return this
   }

AddressToGo = new MakeArray(TotalNumerOfURLs);

var dt = new Date();
var RandomNumber = (dt.getSeconds()%TotalNumerOfURLs)+1;

AddressToGo[1] = "http://www.bucanerosoft.com.ar"
AddressToGo[2] = "http://www.hobbynet.com.ar"
AddressToGo[3] = "http://www.sentinel.com.ar"
AddressToGo[4] = "http://www.bucanerosoft.com.ar/english/help.htm"
AddressToGo[5] = "http://www.ebdesign.com.ar"

function ShowTheBanner() {
   document.write('<CENTER>');
   document.write('<A HREF="', AddressToGo[RandomNumber], '"><IMG SRC="http://www.bucanerosoft.com.ar/gfx/banner', RandomNumber, '.gif" ALT="Visit Our Sponsor!" BORDER=0>');
   document.write('<BR>Visit Our Sponsor!</A>');
   document.write('</CENTER>');
   }

var display_url=1
function showmenu(){
var rightedge=document.body.clientWidth-event.clientX
var bottomedge=document.body.clientHeight-event.clientY

if (rightedge<menu.offsetWidth)
menu.style.left=document.body.scrollLeft+event.clientX-menu.offsetWidth
else
menu.style.left=document.body.scrollLeft+event.clientX

if (bottomedge<menu.offsetHeight)
menu.style.top=document.body.scrollTop+event.clientY-menu.offsetHeight
else
menu.style.top=document.body.scrollTop+event.clientY

menu.style.visibility="visible"
return false
}

function hidemenu(){
menu.style.visibility="hidden"
}

function over(){
if (event.srcElement.className=="menuitems"){
event.srcElement.style.backgroundColor="highlight"
event.srcElement.style.color="yellow"
if (display_url==1)
window.status=event.srcElement.url
}
}

function out(){
if (event.srcElement.className=="menuitems"){
event.srcElement.style.backgroundColor=""
event.srcElement.style.color="black"
window.status=''
}
}

function linkTo(){
if (event.srcElement.className=="menuitems")
window.location=event.srcElement.url
}
