var BTAG = "590036501"; var HostUri = "https://www.dreambingo.co.uk"; var Launch__LoginUri = "/login.asp"; var Launch__OLRUri = "https://www.dreambingo.co.uk/register/dreambingo.aspx?btag=590036501"; var WebOLRUri = "https://register2.valueactive.com/1555/default.asp?clienttype=5&usertype=0&BTAG=" + BTAG; var PopupWindowProperties = "width=800,height=570,status=no,toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no"; var PopupWindowProperties981 = "width=1024,height=700,status=no,toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no"; var PopupWindowProperties1555 = "width=1024,height=700,status=no,toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no"; var RegistrationPopupWindowProperties = "width=840,height=670,status=yes,toolbar=no,menubar=no,location=yes,scrollbars=yes,resizable=no"; var AccountNumberRegEx = "DBR[0-9]{8}$"; var LostPasswordUri = "/lostpassword.asp"; var WindowName__Password = "LostPasswordWindow"; var PopupWindowProperties__Password = "width=480,height=350,status=no,toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no"; var PopupWindowProperties__PasswordMS = "dialogWidth: 480px; dialogHeight: 350px; center: yes; status: no; scroll: no; resizable: no;"; var Message__NoAccNoOrPassword = "Both your Nickname and password are required to login to Bingo."; var Message__PasswordEmailSent = "An email has been sent to [SENTTO]."; var Message__PasswordNoUserName = "Please enter a Nickname."; var Message__PasswordResetComplete = "Your new password has been set."; var Message__PasswordResetFailed = "Sorry, we're unable to change your password at this time."; var Message__PasswordsDontMatch = "The passwords you have entered do not match."; var Message__LostPasswordError = "There was an unknown error requesting your password."; function loginBingo(myform) { if (! window.focus)return true; var d = new Date(); windowname = "BingoWindow1555"; var popupHandle var thisDoc setCookie("loginname", document.getElementById("Username").value, 365); popupHandle=window.open(HostUri+"/BingoShared/lobby/close.htm", windowname, PopupWindowProperties1555); myform.target=windowname; myform.focus(); myform.action=HostUri+"/BingoShared/commands/Connect.aspx"; return true; } function getXMLHttpRequest(){ // branch for native XMLHttpRequest object if(window.XMLHttpRequest) { try { req = new XMLHttpRequest(); } catch(e) { req = false; } // branch for IE/Windows ActiveX version } else if(window.ActiveXObject) { try { req = new ActiveXObject("Msxml2.XMLHTTP"); } catch(e) { try { req = new ActiveXObject("Microsoft.XMLHTTP"); } catch(e) { req = false; } } } if(!req){ alert("Unable to load XMLHttpRequest."); } else { return req; } } function DoBackground(strImage, strField){ document.getElementById(strField).style.backgroundImage = "url(" + strImage + ")"; } function toggleViewAnswer(i){ if(eval('document.all.a' + i).style.display == 'inline'){ eval('document.all.a' + i).style.display = 'none' } else { eval('document.all.a' + i).style.display = 'inline' } } var daysInMonth = ([0,31,29,31,30,31,30,31,31,30,31,30,31]); function daysInFebruary (year) { return ( ((year % 4 == 0) && ( (!(year % 100 == 0)) || (year % 400 == 0) ) ) ? 29 : 28 ); } function Age(bday, bmo, byr) { bmo = bmo - 1; var age; var now = new Date(); tday=now.getDate(); tmo=(now.getMonth()); tyr=(now.getFullYear()); if((tmo > bmo)||(tmo==bmo & tday>=bday)) { age=parseInt(byr); } else { age=parseInt(byr) + 1; } return (tyr - age) } function loadClient(CheckCookie) { if ((getCookie("loginname")=="") && (CheckCookie)) { // window.location.href = Launch__OLRUri window.open( Launch__OLRUri, "BingoRegistrationWindow", RegistrationPopupWindowProperties); } else { window.open( Launch__LoginUri, "BingoWindow1555", PopupWindowProperties1555); } } function loadClientWindow(CheckCookie) { if ((getCookie("loginname")=="") && (CheckCookie)) { window.open( Launch__OLRUri, "BingoRegistrationWindow", RegistrationPopupWindowProperties); } else { window.open( Launch__LoginUri, "BingoWindow1555", PopupWindowProperties1555); } } function accountNumberCheck() { var cookieusername = getCookie("loginname"); if (cookieusername) { document.getElementById("Username").value=cookieusername; } } function loadBingo( username, password, usesamewindow){ if (username&&password){ var xmlHttpConn = getXMLHttpRequest(); if (xmlHttpConn) { username=trim(username.toUpperCase()); var popupHandle var thisDoc if (usesamewindow==0) { try { setCookie("loginname", username, 365); popupHandle=window.open(HostUri+"/BingoShared/lobby/close.htm", "BingoWindow1555", PopupWindowProperties1555) thisDoc=popupHandle.document; thisDoc.open(); thisDoc.clear(); thisDoc.write("