1jQuery(document).ready(function () { 2 if ($("body").hasClass("bodyclass")) { 3 var $window = jQuery(window); 4 5 function check_if_in_view() { 6 7 var $animation_elements = jQuery('.menu-4-links, #footer'); 8 var window_height = $window.height(); 9 var window_top_position = $window.scrollTop(); 10 var window_bottom_position = (window_top_position + window_height); 11 12 $.each($animation_elements, function () { 13 var $element = $(this); 14 var element_height = $element.outerHeight(); 15 var element_top_position = $element.offset().top; 16 var element_bottom_position = (element_top_position + element_height); 17 18 //check to see if this current container is within viewport 19 if ((element_bottom_position >= window_top_position) 20 && (element_top_position <= window_bottom_position)) { 21 $element.addClass("in-view"); 22 } else { 23 $element.removeClass("in-view"); 24 } 25 }); 26 } 27 28 var home_animate = function () { 29 var $window = jQuery(window); 30 $window.bind('scroll smartresize', check_if_in_view); 31 $window.trigger('scroll'); 32 }; 33 34 home_animate(); 35 36 jQuery('body, main').bind('orientationchange', function () { 37 setTimeout(function () { 38 home_animate(); 39 jQuery(window).trigger('scroll'); 40 }, 100); 41 }); 42 } 43 44}); 45 46function scrollFunction() { 47 var scrollBtn = $xa(".scroll-top"); 48 if (document.body.scrollTop > 20 || document.documentElement.scrollTop > 20) { 49 scrollBtn.css("display", "block"); 50 } else { 51 scrollBtn.css("display", "none"); 52 } 53} 54 55function scrollToTop() { 56 document.body.scrollTop = 0; 57 document.documentElement.scrollTop = 0; 58} 59/************ Pills dropdown **************/ 60$(document).ready(function () { 61 62 63 /*********************** ISI expander ***************/ 64 $xa(".resize-isi-icon").on("click", function () { 65 $("#interstitial-overlay").show(); 66 $('.self-cert-interstitial').show(); 67 $('.isi-interstitial').show(); 68 }); 69 70 $xa(".collapse-resize-isi-icon").on("click", function () { 71 $("#interstitial-overlay").hide(); 72 $('.self-cert-interstitial').hide(); 73 $('.isi-interstitial').hide(); 74 }); 75 76 /*********** END ********/ 77 78}); 79 80 81$(document).ready(function () { 82 83 $("a[href='#important-info-xan']").click(function () { 84 $(this).parents('.bodyclass').find('#important-info-xan').parent('.faqAnswer').addClass('expanded'); 85 $(this).parents('.bodyclass').find('.expand-icon').addClass('expanded'); 86 $("html,body").animate({ 87 scrollTop: $("#general-in").offset().top 88 }, "1000"); 89 return false; 90 }); 91 $('.patient_link_header_safety').attr('target', '_blank'); 92}); 93 94/************* Savings **************/ 95$(document).ready(function () { 96 var fullURL = window.location.href; 97 //const getLastItem = thePath => thePath.substring(thePath.lastIndexOf('/') + 1); 98 function getLastItem(thePath) { 99 return thePath.substring(thePath.lastIndexOf('/') + 1); 100 } 101 102 var urlPath = getLastItem(fullURL); 103 if (urlPath === '') { 104 $('header ul.menu-4-links li.home-btn a').addClass('a-active'); 105 } else { 106 $("header ul.menu-4-links li a").each(function () { 107 var eachPath = getLastItem(this.href.toLowerCase()); 108 (urlPath.toLowerCase() == eachPath) ? $(this).addClass("a-active"): $(this).removeClass("a-active"); 109 }); 110 } 111}); 112/************* **************/ 113 114/*********** Singup popup **********/ 115 116$(document).ready(function () { 117 118 $(".close").click(function () { 119 $("#signup-form-load").hide(); 120 $('#interstitial-overlay').hide(); 121 $('body').removeClass('open-popup'); 122 if (localStorage.getItem('popState') != 'shown') { 123 localStorage.setItem('popState', 'shown'); 124 } 125 }); 126 $(".close-icon").click(function () { 127 $(".external-interstitial").hide(); 128 129 }); 130 $(".continue-link").click(function () { 131 $("#signup-form-load").hide(); 132 $('#interstitial-overlay').hide(); 133 $('body').removeClass('open-popup'); 134 if (localStorage.getItem('popState') != 'shown') { 135 localStorage.setItem('popState', 'shown'); 136 } 137 }); 138 $('.top-menu-nav li:last-child a').removeAttr('target'); 139}); 140 141function openpop() { 142 //var popup = document.getElementById("signup-form-load"); 143 localStorage.removeItem('popState'); 144 $("#signup-form-load").show(); 145 $('#interstitial-overlay').show(); 146 $('body').addClass('open-popup'); 147 setTimeout(function () { 148 $("#signup-form-load #PopUpFormRequest #PFirstName").focus(); 149 }); 150 151} 152 153$(document).ready(function () { 154 155 156 $('.close').click(function (e) // You are clicking the close button 157 { 158 $('#signup-form-load').fadeOut(); // Now the pop up is hiden. 159 });
160 161 if (localStorage.getItem('popState') != 'shown') { 162 localStorage.setItem('popState', 'shown'); 163 var popup = document.getElementById("signup-form-load"); 164 165 setTimeout(function () { 166 popup.classList.add("fade-in") 167 }); 168 setTimeout(function () { 169 popup.querySelector('#PopUpFormRequest #PFirstName').focus() 170 }); 171 $('#interstitial-overlay').show(); 172 $('body').addClass('open-popup'); 173 } 174 175}); 176 177$(document).ready(function () { 178var menu = document.querySelector('.signupmenu'); 179if (menu && !menu.querySelector('a img')) { 180$('.signupmenu a').append($('<img>', { 181 src : "/-/media/themes/common/zoloftcom/zoloftcom/images/message_ico.png", 182 width : 30, 183 height : 17, 184 title : "Sign up for more information" 185 186 187})); 188} 189}); 190
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.