/*************************************************************************** MAIN SCRIPT ***************************************************************************/ var maptotal = 0; var mapgraphic = new Array(); var textgraphic = new Array(); var directory = ""; function helloNewWorld() { alert('hello new world'); } function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i -1) { OpenAnyURLNewWindow('/website/website.nsf/glossary?openview&startkey=' + alphabet, 430, 400); } else { alert('There is currently no glossary term starting with the letter ' + alphabet); } } is_ns4up = (document.layers)? true:false is_ie4up = (document.all)? true:false verOK = (is_ns4up || is_ie4up) function changein(id) { if (is_ns4up) document.layers[id].visibility = "show" else if (is_ie4up) document.all[id].style.visibility = "visible" } function changeout(id) { if (is_ns4up) document.layers[id].visibility = "hide" else if (is_ie4up) document.all[id].style.visibility = "hidden" } function goToHomeCalc(){ document.HomeCalcForm.submit(); } function goToTravelCalc(){ document.TravelCalcForm.submit(); } function goToSavingsCalc(){ document.SavingsCalcForm.submit(); } function goToSummitCalc(){ document.SummitCalcForm.submit(); } function goToSpecialSavings(){ document.SpecialForm.submit(); } function nothing(){ } function goToLife() { document.LifeForm.submit() } function goToStandalone() { document.StandaloneForm.submit() } function goToSavingsCalcFT1() { document.SavingsCalcFormFT1.submit() } function goToSavingsCalcFT2() { document.SavingsCalcFormFT2.submit() } function goToSavingsCalcMFI() { document.SavingsCalcFormMFI.submit() } function goToSavingsCalcSG() { document.SavingsCalcFormSG.submit() } function goToSavingsCalcSGI() { document.SavingsCalcFormSGI.submit() } function goToSavingsCalcSGC() { document.SavingsCalcFormSGC.submit() } function goToSavingsCalcSC() { document.SavingsCalcFormSC.submit() } function goToSavingsCalcSA() { document.SavingsCalcFormSA.submit() } function goToSavingsCalcID() { document.SavingsCalcFormID.submit() } function goToSavingsCalcTYA() { document.SavingsCalcFormTYA.submit() } function goToSavingsCalcM90() { document.SavingsCalcFormM90.submit() } function goToSavingsCalcM90I() { document.SavingsCalcFormM90I.submit() } function goToSavingsCalcForm40Day() { document.SavingsCalcForm40Day.submit() } function goToSavingsCalcFormFR() { document.SavingsCalcFormFR.submit() } function goToPIP() { document.PIPForm.submit() } function goToAIR() { document.AIRForm.submit() } function affordability() { document.MortgageAffordability.submit() } function application() { document.MortgageApplication.submit() } function tracker() { document.mortgageTracker.submit() } function repaymentCalculator() { document.RepaymentCalculator.submit() } function goToFixedCalc() { document.FixedCalcForm.submit() } function goToLogin1(customerType){ if (customerType == "Corporate") { document.loginForm.elements["Customer Type"].value = "C"; } else { document.loginForm.elements["Customer Type"].value = "P"; } document.loginForm.submit(); } function HelloWorld() { alert('Hello World'); } // code for going to the ACE insurance web site function goToInsurance(type) { if (confirm("You are about to leave the EBS website and enter an external site which belongs to and is operated by our travel insurance partner, ACE European Group Limited. Please note your use of the ACE European Group Limited website is subject to their terms and conditions. ")) { if (type == 'B') { top.location.href = "http://ebs-business-travelinsurance.ina-box.co.uk/ "; } else if (type == 'M') { top.location.href = "http://ebs-members-travelinsurance.ina-box.co.uk"; } else if (type == "TS") { top.location.href = "http://ebs-travelsave.ina-box.co.uk/"; } else if (type == "65") { top.location.href = "http://ebs-65-plus.ina-box.co.uk/"; } else if (type == "BP") { top.location.href = "http://ebs-backpacker.ina-box.co.uk/"; } else { top.location.href = "http://ebs-public.ina-box.co.uk/"; } } } // code for going to the moneyshow web site function goToMoneyshow( ) { if (confirm("You are about to leave the EBS website and enter the Money Show website to get your free tickets to the seminar. Please note that the Money Show website is subject to their terms and condition.")) { top.location.href = "http://www.themoneyshow.ie/registration.asp "; } } var agt=navigator.userAgent.toLowerCase(); // *** BROWSER VERSION *** // Note: On IE5, these return 4, so use is_ie5up to detect IE5. var is_major = parseInt(navigator.appVersion); var is_minor = parseFloat(navigator.appVersion); // Note: Opera and WebTV spoof Navigator. We do strict client detection. // If you want to allow spoofing, take out the tests for opera and webtv. var is_nav = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1) && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1) && (agt.indexOf('webtv')==-1)); var is_ie = (agt.indexOf("msie") != -1); var is_ie4 = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.")==-1) && (agt.indexOf("msie 6.")==-1) ); if(is_ie4){ window.history.forward();} function getBrowserType() { if(is_nav) document.loginForm.elements["Browser Type"].value = "NN"; else if(is_ie) document.loginForm.elements["Browser Type"].value = "IE"; else document.loginForm.elements["Browser Type"].value = "NA"; } function goToLogin(customerType){ if (customerType == "Corporate") { document.loginForm.elements["Customer Type"].value = "C"; } else { document.loginForm.elements["Customer Type"].value = "P"; } getBrowserType(); document.loginForm.submit(); } function goToLoginBig(){ getBrowserType(); document.loginFormBig.submit(); } function goToLoginTeen(){ getBrowserType(); document.loginFormTeen.submit(); } function submitForm(apptype){ var Pat = /MSIE 5\.0b2/; if (Pat.test(navigator.appVersion)) document.SpecialForm.IE50Browser.value = "Y"; else document.SpecialForm.IE50Browser.value = "N"; document.SpecialForm.submit(); } function goToLumpSum() { document.LumpSumForm.submit() } function goToSummit(flag) { if (flag == 'M') { document.SummitForm.elements["Summit Type"].value = 'Mutual'; document.SummitForm.elements["Product Code"].value = 'M10'; } if (flag == 'I') { document.SummitForm.elements["Summit Type"].value = 'Investment'; document.SummitForm.elements["Product Code"].value = 'N10'; } document.SummitForm.submit() } function retrieveapplication() { var Pat = /MSIE 5\.0b2/; if (Pat.test(navigator.appVersion)) { document.returnToApplication.IE50Browser.value = "Y"; } else { document.returnToApplication.IE50Browser.value = "N"; } document.returnToApplication.submit() } function submitFormCallSeven(){ document.linkform.action = "http://online.ebs.ie/internet/features/csaccmain.jsp"; document.linkform.submit(); } function submitFormDiamond(){ document.linkform.action = "http://online.ebs.ie/internet/features/daccmain.jsp"; document.linkform.submit(); } function submitFormFixed(){ document.linkform.action = "http://online.ebs.ie/internet/features/ftaccmain.jsp"; document.linkform.submit(); } function submitFormExistingCorporate(){ document.linkform.action = "https://online.ebs.ie/internet/features/register.jsp"; document.linkform.submit(); } function submitFormExistingPersonal(){ document.linkform.action = "https://online.ebs.ie/internet/features/registerpersonal.jsp"; document.linkform.submit(); } function goToPaymentProtection() { document.PaymentProtectionForm.submit(); } function goToBuyToLetCalc() { document.BuyToLetForm.submit() } function goToHomeContentsOnlyCalc() { document.HomeContentsOnlyCalcForm.submit() } //get checked value from Radio Button function getRadioValue(docField) { var checkedValue = '' alert('length is ' + docField.length); for (i = 0; i < docField.length; i++) { if (docField[i].checked) { checkedValue = docField[i].value; break } } return checkedValue; } //make sure a check box or radio button has something selected function validateAllChecked(docField, name, anchor) { //alert(docField.length); validated = true; for (i = 0; i < docField.length; i++) { if (!docField[i].checked) { //alert(docField[i].value); validated = false; break; } } return validated } function validateVISA(doc) { if(!validateAllChecked(document.forms[0].Q1, "Q1. I am over the age of 18", "")) { alert("You must tick all boxes before you can proceed."); return false; } window.location.href='/site/all/EBS+Member+Credit+Card+Application?opendocument'; return true; } function validatePersonalLoan(doc) { if (document.getElementById("Question").checked) { window.location.href='/site/all/EBS+Personal+Loan+Application?opendocument'; return true; } else { alert('You must be an EBS Member'); return false; } //if(!validateAllChecked(document.getElementById("Question"), "Q1. I am an EBS member", "")) return false; //if(!validateAllChecked(document.forms[1].Q1, "Q1. I am over the age of 18", "")) return false; //window.location.href='/site/all/EBS+Personal+Loan+Application?opendocument'; //return true; } function whichForm() { var allforms = ''; for (var i=0; i