Ducati Diavel V4 launched in India, bollywood actor Ranveer Singh appointed as brand ambassador

" + planDescName + " ₹ " + planPrice + "

" + nextBillingHtml + "

"; } doc.getElementById("userPlanMSSec").innerHTML = html; document.getElementById("userPlanMSSec").vogue = "display: block;"; } else if (planData.plan.plan_type.toLowerCase().comprises("wsj") && wsjEmail != "") showWsjWidget=actual; subscriptionInfoBox = getSubscriptionInfo(planDescription, planName, nextBillingHtml, showWsjWidget, msStoryId, nextActivationDate, planCode); let manageSubsLink = (nextActivationDate && planCode)?"control SUBSCRIPTION":""; html = "

"+subscriptionInfoBox+"

"+manageSubsLink; doc.getElementById("userPlanMSSec").innerHTML = html; doc.getElementById("userPlanMSSec").style = "display: block;"; getWsjStatus(wsjEmail); else subscriptionInfoBox = getSubscriptionInfo(planDescription, planName, nextBillingHtml, showWsjWidget, msStoryId, nextActivationDate, planCode); let manageSubsLink = (nextActivationDate && planCode)?"manage SUBSCRIPTION":""; html = "

"+subscriptionInfoBox+"

"+manageSubsLink; doc.getElementById("userPlanMSSec").innerHTML = html; doc.getElementById("userPlanMSSec").trend = "reveal: block;"; } capture(e) console.log(e); } } } else if (!doc.getElementById("userProfileInfo").classList.carries("subsUpdated")) getSubscribeNow(); } } feature getMsStroyId()if (typeof subsStoryId != 'undefined' && subsStoryId) return subsStoryId; else if (typeof storyID != 'undefined' && storyID) return storyID; else if (typeof storyId != 'undefined' && storyId) return storyId; else return ''; function getNextBilling(billingCycleText, nextActivationDate)let nextBillingMonth = new Date(nextActivationDate).toDateString().break up(" ")[1]; let nextBillingDay = new Date(nextActivationDate).getUTCDate(); let nextBillingYear = new Date(nextActivationDate).getFullYear(); let nextBillingHtml = (nextBillingDay && nextBillingMonth && nextBillingYear) ? billingCycleText + nextBillingDay + " " + nextBillingMonth + " " + nextBillingYear : ""; return nextBillingHtml; function getNextActivationDate(planData) if (planData.next_billing_at != "" && planData.next_billing_at != "null" && typeof planData.next_billing_at != "undefined") billingCycleText = "next Billing Date : "; nextActivationDate = planData.next_billing_at; else if (planData.expires_at != "" && planData.expires_at != "null" && typeof planData.expires_at != "undefined") billingCycleText = "Expiry date : "; nextActivationDate = planData.expires_at; else billingCycleText = "Expiry date : "; nextActivationDate = planData.current_term_ends_at; return [billingCycleText, nextActivationDate]; feature getSubscribeNow() let msgEl = doc.createElement("div"); msgEl.classList.add("newBlock"); msgEl.classList.add("planSec"); msgEl.innerHTML = "Subscribe Now"; doc.getElementById("userProfileInfo").after(msgEl); doc.getElementById("userProfileInfo").classList.add("subsUpdated"); function getProfileBox(name, electronic mail ) if(document.getElementById("uName") && identify && email) document.getElementById("uName").innerHTML = "" + identify + "" + e mail + "Edit"; function closePopUp(elm) var isSubscribedCookie = getCookie("isSubscribed"); if (isSubscribedCookie !== "undefined" && isSubscribedCookie) setCookieNewsletter("isSubscribed", isSubscribedCookie, -1); if (elm !== "undefined" && elm && document.getElementById(elm)) document.getElementById("newsltrOvrlay").style.monitor = "none"; document.getElementById(elm).trend.reveal = "none"; feature openUserSideProfile() closePopUp("thnkNewsletter"); getUserData(); ga("ship", "experience", "my_account", "click on"); document.getElementById("myAccount").fashion.width = "320px"; document.getElementById("Userbgoverlay").style.screen = "block"; var trackData = ; trackWebEngageEvents("My Account seen", trackData); function closeUserSideProfile() doc.getElementById("myAccount").style.width = "0"; document.getElementById("Userbgoverlay").trend.display = "none"; feature goToManageSubscriptions(storyId, tenureEndDate, currentPlanName, pixelCapieventName) let redirectUrl = "https://debts.hindustantimes.com/lm/managesubscription"; let queryParamString = trackRenewClick(storyId, tenureEndDate, currentPlanName); fireCapiService(pixelCapieventName); redirectUrl += queryParamString; redirectUrl += "&check_app=actual"; setTimeout(() => window.region.href = redirectUrl; , 500) characteristic isWithinDiscounted(tenureEndDate) are trying trap (e) console.log(e); return false; function showRenewNowFlag(planType, tenureStartDate, renewedUserFlag) try if (renewedUserFlag) return false; if (planType.toLowerCase().comprises("wsj")) return proper; else if (dateDiff(tenureStartDate) > 14) return true; else return false; seize (e) console.log(e); return false; function dateDiff(date) const dateCompare = new Date(date); const dateToday = new Date(); const diffTime = dateToday - dateCompare; const diffDays = Math.ceil(diffTime / (one thousand * 60 * 60 * 24)); return diffDays; function getDaysInExpiry(tenureEndDate) are attempting const diffDays = dateDiff(tenureEndDate) - 1; let daysInExpiry = ""; if (diffDays > 0) daysInExpiry = "D+" + diffDays; else daysInExpiry = "D" + diffDays; return daysInExpiry; capture (e) console.log(e); return ""; feature getWsjStatus(wsjEmail) var wsjStatusHtml = ""; var xhrWsj = new XMLHttpRequest(); xhrWsj.onreadystatechange = feature() if (xhrWsj.readyState === four) var dataWsj = JSON.parse(xhrWsj.responseText); if (dataWsj && typeof dataWsj.records!="undefined" && typeof dataWsj.statistics.redemption_code_status!="undefined" && dataWsj.information.redemption_code_status) let redemptionCodeStatus = dataWsj.information.redemption_code_status; if (redemptionCodeStatus == "EXHAUSTED") wsjStatusHtml = "Your The WSJ subscription is lively"; document.getElementById("activateWsj").innerHTML = wsjStatusHtml; doc.getElementById("subsInfoContainer").classList.add("activatedSubscription"); doc.getElementById("activateWsj").vogue.monitor = "block"; else if (typeof dataWsj.facts.redemption_url !="undefined" && dataWsj.facts.redemption_url) wsjStatusHtml = "set off The Wall road Journal"; document.getElementById("activateWsj").innerHTML = wsjStatusHtml; document.getElementById("activateWsj").vogue.monitor = "block"; else document.getElementById("activateWsj").trend.reveal = "none"; console.log("redemption url isn't found"); ; xhrWsj.open("GET", "/subscription/fetch/wsjStatus/" + wsjEmail); xhrWsj.send(); characteristic hideOnPhonePe() var userAgent = navigator.userAgent; var objectsToHide = document.getElementsByClassName("hideOnPhonePe"); if (userAgent.comprises("phonepe-webview") && objectsToHide.length != 0) for (i = 0; i < objectsToHide.size; i++) objectsToHide[i].fashion.display = "none"; var publicationsObj; function getBundlePlanDesc(basePlan) if (!basePlan) return; return basePlan.map((p) => getBrandName(p)).join("+"); feature getBrandName(brandCode) if (!publicationsObj) return brandCode; if (!publicationsObj.planName) return brandCode; if (!publicationsObj.planName[brandCode]) return brandCode; return publicationsObj.planName[brandCode]; feature fetchPublications() return fetch("/json/publications.json").then((resp) => resp.json()).then((resp) => if (resp.success) publicationsObj = resp.data; ).trap((err) => console.log("failed to fetch publicatons", err)); function getPlanNameByBasePlan(basePlan) if (!basePlan) return; return basePlan.map((plan) => replaceAll(getBrandName(publicationsObj.planNameEvent[plan])), " ", "_").be part of(";"); function whatsappCtaClick() if (whatsappOpted == genuine) trackWebEngageEvents("manage_whatsapp_updates_clicked", trackDataWa); Moengage.track_event("manage_whatsapp_updates_clicked", Gender: trackDataWa["Gender"], Plan: trackDataWa["Plan"], "Registered at": trackDataWa["Registered at"], isSubscribed: trackDataWa["isSubscribed"], origin: trackDataWa["Origin"] ); var whatsappOptInUrl = "https://debts.hindustantimes.com/whatsapp_opt_in?ref=lm" + "&Gender=" + trackDataWa["Gender"] + "&Plan=" + trackDataWa["Plan"] + "&Registered_at=" + trackDataWa["Registered at"] + "&isSubscribed=" + trackDataWa["isSubscribed"] + "&beginning=" + trackDataWa["Origin"]; window.area.href = whatsappOptInUrl; else trackWebEngageEvents("get_alert_on_whatsapp_clicked", trackDataWa); Moengage.track_event("get_alert_on_whatsapp_clicked", Gender: trackDataWa["Gender"], Plan: trackDataWa["Plan"], "Registered at": trackDataWa["Registered at"], isSubscribed: trackDataWa["isSubscribed"], foundation: trackDataWa["Origin"] ); if (typeof isSubscribedUser != "undefined" && isSubscribedUser != null) if (isSubscribedUser == authentic) var whatsappOptInUrl = "https://debts.hindustantimes.com/whatsapp_opt_in?ref=lm" + "&Gender=" + trackDataWa["Gender"] + "&Plan=" + trackDataWa["Plan"] + "&Registered_at=" + trackDataWa["Registered at"] + "&isSubscribed=" + trackDataWa["isSubscribed"] + "&starting place=" + trackDataWa["Origin"]; window.region.href = whatsappOptInUrl; else toggleWhatsappNonSubsPopUp(authentic); feature trackRenewClick(storyId, tenureEndDate, currentPlanName) let targetStorySection = ""; let targetStorySubSection = ""; let targetStoryURL = ""; let targetStoryTitle = ""; let targetStoryAuthorName = ""; let expiryPeriod = ""; let targetStoryAgency = ""; let trackData = ; try if (typeof storyId != "undefined" && storyId != null && storyId.trim() != "") const targetBoxDivId = "box_" + storyId.trim(); const targetBoxDivEl = document.getElementById(targetBoxDivId); const targetArticleDivId = "article_" + storyId; try targetStorySection = targetBoxDivEl.closest("[data-vars-section]").getAttribute("information-vars-area"); capture (e) if (typeof snowplowSection != "undefined") targetStorySection = snowplowSection; console.log(e); try targetStorySubSection = targetBoxDivEl.closest("[data-vars-subsection]").getAttribute("information-vars-subsection"); trap (e) console.log(e); are attempting targetStoryURL = domainURLEvents + targetBoxDivEl.closest("[data-weburl]").getAttribute("information-weburl"); capture (e) console.log(e); are trying if (doc.getElementById("headline_" + storyId) !== null) targetStoryTitle = document.getElementById("headline_" + storyId).innerText; capture (e) console.log(e); try const authEl = doc.getElementById(targetArticleDivId).getElementsByClassName("author")[0]; if (typeof authEl.innerText != 'undefined' && authEl.innerText != null) targetStoryAuthorName = authEl.innerText; else targetStoryAuthorName = ""; seize (e) console.log(e); are attempting targetStoryAgency = targetBoxDivEl.closest("[data-vars-agency]").getAttribute("information-vars-company"); catch (e) console.log(e); are trying expiryPeriod = getDaysInExpiry(tenureEndDate); catch (e) expiryPeriod = ""; console.log(e); trackData.area = "LM"; trackData["Article Section"] = targetStorySection; trackData["Article Subsection"] = targetStorySubSection; trackData["Article Id"] = storyId; trackData["Article Title"] = targetStoryTitle; trackData["Author Name"] = targetStoryAuthorName; trackData["Expiry Period"] = expiryPeriod; trackData["Plan Name Before Renewal"] = currentPlanName; trackData["Manage Plan Page Reason"] = "my_account"; trackData.Platform = "internet"; trackData["Campaign Reason"] = ""; trackData["Agency"] = targetStoryAgency; if (typeof currentPlanPrice != "undefined") trackData["Amount Paid Before Upgrade"] = currentPlanPrice; else trackData["Amount Paid Before Upgrade"] = ""; if (typeof monthsUtilized != "undefined") trackData["No of Months"] = monthsUtilized; else trackData["No of Months"] = ""; var gaData = dimension22: "LM", dimension23: trackData["Manage Plan Page Reason"], dimension26: trackData["Campaign Reason"], dimension48: trackData["Expiry Period"], dimension49: trackData["Article Section"], dimension50: trackData["Article Subsection"], dimension51: trackData["Article Id"], dimension3: trackData["Author Name"], dimension66: currentPlanName, dimension84: monthsUtilized, dimension85: currentPlanPrice, dimension82: targetStoryAgency ; gaTrackingEvent1("subscription", "renew_now_clicked", trackData["Article Title"], gaData); Moengage.track_event("renew_now_clicked", trackData); catch (e) console.log(e); return "?domain=" + trackData["domain"] + "&article_section=" + trackData["Article Section"] + "&article_subsection=" + trackData["Article Subsection"] + "&article_id=" + trackData["Article Id"] + "&article_title=" + trackData["Article Title"] + "&author_name=" + trackData["Author Name"] + "&expiry_period=" + trackData["Expiry Period"] + "&plan_name_before_renewal=" + trackData["Plan Name Before Renewal"] + "&manage_plan_page_reason=" + trackData["Manage Plan Page Reason"] + "&platform=" + trackData["Platform"] + "&company=" + targetStoryAgency;

Comments

Popular posts from this blog

The Blockbuster That Hollywood turned into Afraid to Make

Why Bollywood continues to be 'sexist and regressive'

‘Koi Mil Gaya’ villain Raj Saxena aka Rajat Bedi opens up about why he stop Bollywood – ‘Getting established is fine,