loginWin = null; function openLoginWindow () { var affiliateID = 0; var subAffiliate = 136; var host = 'http://flash.ibingo.com/beta2/'; var hostPHP = 'http://flash.ibingo.com/beta2/'; if (affiliateID == 7) { host = 'http://flash.bonkers4bingo.com/'; hostPHP = host; } var openNew = true; if (loginWin) { if (!loginWin.closed) openNew = false; } if (openNew) { var w = 400; var h = 380; var phpFile = "newlogin.php"; var x = 0; var y = 0; if (window.screen) { x = Math.round ((screen.availWidth - w) / 2); y = Math.round ((screen.availHeight - h) / 2); if (x<0 || w>screen.availWidth) x = 0; if (y<0 || h>screen.availHeight) y = 0; } var now = new Date(); loginWin = window.open (hostPHP + phpFile + "?gID=" + now.getTime() + "&loginID=0" + "&subAffiliate=" + subAffiliate + "&affiliateID=" + affiliateID + "&host=" + host + "&hostPHP=" + hostPHP, "Login", "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0," + "resizable=0,width=" + w + ",innerWidth=" + w + ",height=" + h + ",innerHeight=" + h + ",left=" + x + ",top=" + y + ",screenX=" + x + ",screenY=" + y); } loginWin.focus(); } ttgWin = null; function openTTG () { var affiliateID = 0; var subAffiliate = 136; var hostTTG = 'http://www.tothegames.com/'; var openNew = true; if (ttgWin) { if (!ttgWin.closed) openNew = false; } if (openNew) { var w = 520; var h = 520; var phpFile = "ttg.php"; var x = 0; var y = 0; if (window.screen) { x = Math.round ((screen.availWidth - w) / 2); y = Math.round ((screen.availHeight - h) / 2); if (x<0 || w>screen.availWidth) x = 0; if (y<0 || h>screen.availHeight) y = 0; } var now = new Date(); ttgWin = window.open (hostTTG + phpFile + "?gID=" + now.getTime() + "&loginID=0" + "&affiliateID=" + affiliateID + "&subAffiliate=" + subAffiliate, "TTG", "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1," + "resizable=0,width=" + w + ",innerWidth=" + w + ",height=" + h + ",innerHeight=" + h + ",left=" + x + ",top=" + y + ",screenX=" + x + ",screenY=" + y); } ttgWin.focus(); }