function checkip1(){ //alert('here'); var ip = document.getElementById('ipaddress').value; //alert(document.getElementById('ipaddress').value); if ( window.XMLHttpRequest){ http = new XMLHttpRequest(); } else if ( window.ActiveXObject ){ http = new ActiveXObject("Microsoft.XMLHTTP"); } http.onreadystatechange = httpChanges3; try { url = "/dating/checkip.php?ipaddress="+document.getElementById('ipaddress').value; //url = "/dating/checkip.php?ipaddress=81.174.147.164"; http.open("GET",url,true); http.send(null); } catch (e) { alert(e); } } function httpChanges3(){ //alert(http.readyState); if ( http.readyState == 4 ){ var x = http.responseText; if(x=="invalid") { alert("You appear to be registering from outside the UK. We only accept UK registrations. If you think this is incorrect,please telephone us on 0870 7662516"); return false; } else { document.getElementById("loginForm").submit(); return true; } } } function checkip4(){ //alert('here'); var ip = document.getElementById('ipaddress').value; //alert(document.getElementById('ipaddress').value); if ( window.XMLHttpRequest){ http = new XMLHttpRequest(); } else if ( window.ActiveXObject ){ http = new ActiveXObject("Microsoft.XMLHTTP"); } http.onreadystatechange = httpChanges4; try { url = "/dating/checkip.php?ipaddress="+document.getElementById('ipaddress').value; //url = "/dating/checkip.php?ipaddress=81.174.147.164"; http.open("GET",url,true); http.send(null); } catch (e) { alert(e); } } function httpChanges4(){ //alert(http.readyState); if ( http.readyState == 4 ){ var x = http.responseText; if(x=="invalid") { alert("You appear to be registering from outside the UK. We only accept UK registrations. If you think this is incorrect,please telephone us on 0870 7662516"); return false; } else { document.getElementById("loginForm2").submit(); return true; } } } function checkip5(){ //alert('here'); var ip = document.getElementById('ipaddress').value; //alert(document.getElementById('ipaddress').value); if ( window.XMLHttpRequest){ http = new XMLHttpRequest(); } else if ( window.ActiveXObject ){ http = new ActiveXObject("Microsoft.XMLHTTP"); } http.onreadystatechange = httpChanges5; try { url = "/dating/checkip.php?ipaddress="+document.getElementById('ipaddress').value; //url = "/dating/checkip.php?ipaddress=81.174.147.164"; http.open("GET",url,true); http.send(null); } catch (e) { alert(e); } } function httpChanges5(){ //alert(http.readyState); if ( http.readyState == 4 ){ var x = http.responseText; if(x=="invalid") { alert("You appear to be registering from outside the UK. We only accept UK registrations. If you think this is incorrect,please telephone us on 0870 7662516"); return false; } else { document.getElementById("loginForm3").submit(); return true; } } } function Trim(nStr) { return nStr.replace(/(^\s*)|(\s*$)/g, ""); } function openHelp1(topicID,pac_id) { if (topicID) { //window.open("/core/help.html?id="+topicID,"helpWindow","width=385,height=375,scrollbars=yes,resizable=yes"); window.open("/core/help.html?package_id="+pac_id+"&id="+topicID,"helpWindow","height=700,width=900,status=yes,toolbar=no,menubar=no,location=no,scrollbars=yes,left=0,top=0,resizable=1"); } } function openHelp(topicID) { if (topicID) { //window.open("/core/help.html?id="+topicID,"helpWindow","width=385,height=375,scrollbars=yes,resizable=yes"); window.open("/core/help.html?id="+topicID,"helpWindow","height=700,width=900,status=yes,toolbar=no,menubar=no,location=no,scrollbars=yes,left=0,top=0,resizable=yes"); } if (!topicID) { // window.open("/core/help.html","helpWindow","width=385,height=375,scrollbars=yes,resizable=yes"); window.open("/core/help.html","helpWindow","height=700,width=900,status=yes,toolbar=no,menubar=no,location=no,scrollbars=yes,left=0,top=0,resizable=yes"); } } function openPackageUpgrade() { window.open("/common/upgrade.html","UpgradePackage","height=500,width=500,scrollbars=yes,resizable=yes"); } function profilePhotoManager() { window.open("/dating/photomanager.html","photoManager","width=500,height=500,scrollbars=Yes,resizable=yes"); } function profilePhotoViewer(userID) { window.open("/dating/photoviewer.html?id="+userID,"photoViewer","width=500,height=500,scrollbars=yes,resizable=yes"); } function transactionViewer(transactionID) { window.open("/common/credittransaction.html?id="+transactionID,"fullTransaction","width=500,height=500,scrollbars=yes,resizable=yes"); } function addFloats(floatA,floatB) { // add two floats together, because on its own JavaScript // sometimes runs out of fingers var intA = Math.round(floatA * 100); var intB = Math.round(floatB * 100); var intC = intA + intB; return (intC / 100); } function subtractFloats(floatA,floatB) { // subtracts floatB from floatA, because on its own JavaScript // sometimes runs out of fingers var intA = Math.round(floatA * 100); var intB = Math.round(floatB * 100); var intC = intA - intB; return (intC / 100); } function enableDateMenu(prefix) { // enables the prefixed date menu group // see also DateMenu() PHP function if (document.getElementById(prefix+'_enable').type == "checkbox") { if (document.getElementById(prefix+'_enable').checked == true) { document.getElementById(prefix+'_day').disabled = false; document.getElementById(prefix+'_month').disabled = false; document.getElementById(prefix+'_year').disabled = false; } else { document.getElementById(prefix+'_day').disabled = true; document.getElementById(prefix+'_month').disabled = true; document.getElementById(prefix+'_year').disabled = true; } } else { document.getElementById(prefix+'_day').disabled = false; document.getElementById(prefix+'_month').disabled = false; document.getElementById(prefix+'_year').disabled = false; } } function disableDateMenu(prefix) { // disables the prefixed date menu group // see also DateMenu() PHP function document.getElementById(prefix+'_day').disabled = true; document.getElementById(prefix+'_month').disabled = true; document.getElementById(prefix+'_year').disabled = true; } function verifyDelete(confLocation) { // for use with DTMLRecordSummary() // verifies the user's intention to delete a record before proceeding // with the supplied confLocation redirect if (confirm('Are you sure you wish proceed with this action?')) { location.href=confLocation; } } function changeClass(id,newClass) { // changes CSS class of id to newClass identity=document.getElementById(id); identity.className=newClass; } function updateDropDownTextBox(formField,opMode) { // supporting function for the "dropdowntextbox" DTML widget type // objects var textBox = document.getElementById(formField); var selList = document.getElementById(formField+'_dtmllist'); // read list menu var menuItems = Array(); var i=0; do { menuItems[i] = selList.options[i].value; } while (++i < selList.length); if (opMode == "box2list") { if (textBox.value) { for (i=0; i= 5) // JScript gives us Conditional compilation, we can cope with old IE versions. // and security blocked creation of the objects. try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } } @end @*/ if (!xmlhttp && typeof XMLHttpRequest!='undefined') { xmlhttp = new XMLHttpRequest(); } return xmlhttp; } function formElementLimiter(obj,maxlimit ) { if ( obj.value.length > maxlimit ) { obj.value = obj.value.substring( 0, maxlimit ); obj.blur(); obj.focus(); return false; } } function bookmarksite(title, url){ if (document.all){ window.external.AddFavorite(url, title);} else if (window.sidebar) window.sidebar.addPanel(title, url, "") } function openNickSuggester() { openHelp(4); } function suggestNickname(forename,userid) { if (Trim(forename)!="") { document.getElementById('nsf').style.display = "none"; document.getElementById('nsr').style.display = "inline"; document.getElementById('nsr').innerHTML = "Checking ..."; populateHTTPObject("nsr","GET","suggestnick.php?id="+userid+"&forename="+Trim(forename)); } else { alert("Please enter your first name"); } } function StartVideo() { document.MediaPlayer.controls.play(); document.getElementById('playbutton').disabled = true; document.getElementById('stopbutton').disabled = false; document.getElementById('pausebutton').disabled = false; } function StopVideo() { document.MediaPlayer.controls.stop(); document.getElementById('playbutton').disabled = false; document.getElementById('stopbutton').disabled = true; document.getElementById('pausebutton').disabled = true; } function PauseVideo() { document.MediaPlayer.controls.pause(); document.getElementById('playbutton').disabled = false; document.getElementById('stopbutton').disabled = false; document.getElementById('pausebutton').disabled = true; } function fnSendmsg(arg) { window.location.href=arg; } function fnhelpopen() { window.close(this); window.open("/core/help_new.html",null,"height=700,width=900,status=yes,toolbar=no,menubar=no,location=no,left=0,top=0,resizable=1"); }