Get Cox Fiber | Cox fiber network is coming to your neighborhood (2024)

\

\ '; if (staticSection.find('.address-text').length == 0) { if (window.location.search.match(/addressEntered=true/ig) != null) { staticSection.append(addressFieldWithChangeLink); } if (window.location.search.match(/addressActiveService=true/ig) != null) { $('#addressCaptureEntry, #heroAddressCaptureEntry').find('h2').first().parent().append(addressFieldWithChangeLink); } } if (stickySection.find('.address-text').length == 0) { stickySection.append(addressFieldWithChangeLink); } // Add the provided address to the DOM if (typeof utag_data.pAddressApartment != 'undefined') { $('.address-text').html(utag_data.pAddressStreet + ', Unit #' + utag_data.pAddressApartment + ', ' + utag_data.pAddressZip); } else { $('.address-text').html(utag_data.pAddressStreet + ', ' + utag_data.pAddressZip); } } // ?editAddress, ?addressEntered, etc. Special treatment for the 5G page if (window.location.pathname.match(/cox-internet-vs-5g-home-internet.html/ig) != null && hasScrolled == false) { if (window.location.search.match(/editAddress=true/ig) != null) { $(document).ready(function () { // Scroll the user down to the address section of the page setTimeout(function () { $('html, body').animate({ scrollTop: $('#addressCaptureEntry').first().offset().top - 10 }, 500); }, 1500); }); } else if (window.location.search.match(/address/ig) != null) { $(document).ready(function () { // Scroll the user down to the address section of the page setTimeout(function () { $('html, body').animate({ scrollTop: $('#offerControl').first().offset().top - 10 }, 500); }, 1500); }); } } if (window.location.search.match(/editAddress=true/ig) != null && hasScrolled == false) { $(document).ready(function () { // Scroll the user down to the address section of the page setTimeout(function () { $('html, body').animate({ scrollTop: $('#addressCaptureEntry').offset().top - 10 }, 500); }, 1500); }); // Clear address field data when the user begins to enter a new address $('#addressCaptureEntry .street-address, #addressCaptureEntry .unit, #addressCaptureEntry .postal-code').focus(function (e) { // Empty the field but keep the old street address value in case the user decides not to change it if ($(e.currentTarget).val() == utag_data.pAddressStreet || $(e.currentTarget).val() == utag_data.pAddressApartment || $(e.currentTarget).val() == utag_data.pAddressZip) { $(e.currentTarget).val(''); } }); hasScrolled = true; } } // Remove empty .address-container sections $('.address-container').each(function (i, e) { if ($(e).children().length == 0) { $(e).remove(); } }); // Show all fields by toggle the class '.reveal-all-fields' after a street address is provided $('.street-address').unbind('keydown keyup blur'); $('.street-address').on('keydown keyup blur', function (e) { if ($(e.currentTarget).val().length) { $(e.currentTarget).parents('form').first().find('.address-container').addClass('reveal-all-fields'); $(e.currentTarget).parents('.address-container').siblings('.address-container').removeClass('hide'); } else { $(e.currentTarget).parents('form').first().find('.address-container').removeClass('reveal-all-fields'); $(e.currentTarget).parents('.address-container').siblings('.address-container').addClass('hide'); } }); // Reveal all fields when address data is already present (from outside the scope of this script) $('.street-address').each(function (i, e) { if (e.value.length) { $(e).parents('form').first().find('.address-container').addClass('reveal-all-fields'); $(e).parents('.address-container').siblings('.address-container').removeClass('hide'); } }); // Set placeholder text for form fields $('.residential-address-form .unit').attr('placeholder', 'Unit #'); $('.residential-address-form .postal-code').attr('placeholder', 'ZIP code'); // Hide 'Check availability' button for the active-service result if (window.location.href.match(/addressActiveService=true/ig) != null) { $('.address-entry-box-container, .address-entry-sticky-container').addClass('active-service-scenario'); } $('.street-address').attr('placeholder', 'Street Address, Apt/Unit, Zip Code'); } var observer = new MutationObserver(function (diffs) { $.each(diffs, function (i, diff) { // Remove empty .address-container sections $('.address-container').each(function (i, e) { if ($(e).children().length == 0) { $(e).remove(); } }); }); }); observer.observe($('body').get(0), { attributes: true, childList: true, subtree: true });

Get Cox Fiber | Cox fiber network is coming to your neighborhood (2024)
Top Articles
Latest Posts
Article information

Author: Chrissy Homenick

Last Updated:

Views: 5296

Rating: 4.3 / 5 (74 voted)

Reviews: 89% of readers found this page helpful

Author information

Name: Chrissy Homenick

Birthday: 2001-10-22

Address: 611 Kuhn Oval, Feltonbury, NY 02783-3818

Phone: +96619177651654

Job: Mining Representative

Hobby: amateur radio, Sculling, Knife making, Gardening, Watching movies, Gunsmithing, Video gaming

Introduction: My name is Chrissy Homenick, I am a tender, funny, determined, tender, glorious, fancy, enthusiastic person who loves writing and wants to share my knowledge and understanding with you.