// Need to set this variable so Talisma can read lang as a custom variable talCustProp = "lang=" + proactive_lang; var isProactiveEnglish = (proactive_lang == "fr") ? false : true; // English by default if proactive_lang is invalid var proactiveLangAbbr = isProactiveEnglish ? "en" : "fr"; var isStartPage = false try { isStartPage = (proactive_invite == "startpage") ? true : false; } catch (e) {} var cssFilename = "css/proactive.css"; var jsFilename = "js/proactive.js"; if (isStartPage) { cssFilename = "css/proactive_start_" + proactiveLangAbbr + ".css"; jsFilename = "js/proactive_start.js"; } var featureNameArray = ["Mail", "Security", "Account", "Wireless"]; var enFeatureValueArray = ["mail", "security", "account", "wireless"]; var frFeatureValueArray = ["courriel", "sécurité", "compte", "sans-fil"]; var featureValueArray = (proactive_lang == "fr") ? frFeatureValueArray : enFeatureValueArray; // Outputs html for proactive chat function createProactiveHtml() { var popupwinDiv = oPopup; // oPopup is defined in parent vbscript //var popupwinDiv = document.createElement("div"); //popupwinDiv.id = "popupwin"; //popupwinDiv.style.display = "none"; //popupwinDiv.style.display = "block"; //document.body.appendChild(popupwinDiv); var popupwinDivHtml = ''; if (isStartPage) { // Update position popupwinDiv.style.left = "180px"; popupwinDiv.style.top = "150px"; // Set background var popupWinBgUrl = prefix + 'invite_images/popup_bg_startpage_' + proactiveLangAbbr + '.gif'; popupwinDiv.style.backgroundImage = 'url(' + popupWinBgUrl + ')'; // Language-based feature labels var featureLabels; if (isProactiveEnglish) { featureLabels = ["Your Bell Mail", "Your Bell Internet Security", "Your Account Details", "Your Wireless Home Network"]; } else { featureLabels = ["Votre Courriel Bell", "Vos services de sécurité Bell Internet", "Les détails de votre compte", "Votre réseau sans fil à domicile"]; } popupwinDivHtml = ''; popupwinDivHtml += '
' + "\n"; popupwinDivHtml += '
' + "\n"; popupwinDivHtml += '' + "\n"; // Loop over features for (var featureIdx = 0; featureIdx < featureLabels.length; featureIdx++) { var featureName = featureNameArray[featureIdx]; var featureNameLower = featureName.toLowerCase(); var featureValue = featureValueArray[featureIdx]; var checkboxId = "proactiveFeature" + featureName; popupwinDivHtml += '' + "\n"; popupwinDivHtml += '
'; popupwinDivHtml += '
'; popupwinDivHtml += ''; popupwinDivHtml += '' + "\n"; popupwinDivHtml += '
' + "\n"; popupwinDivHtml += '