From 5925f4e7c72c58399efe6703f6e8eeac8c1f09c2 Mon Sep 17 00:00:00 2001 From: Anthony Talarico Date: Wed, 3 Aug 2016 15:49:35 -0400 Subject: [PATCH] re adding sticky header after finding out the ad rotate is broken due to ad blocker being installed --- js/app.js | 26 +++++++++++++------------- js/custom/pageSetup.js | 26 +++++++++++++------------- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/js/app.js b/js/app.js index 03e3aa3..c3108d6 100644 --- a/js/app.js +++ b/js/app.js @@ -50,18 +50,18 @@ $(document).ready(function () { this.title = $(this.element).find('img').attr('alt'); } }); -// var body = $("body"); -// var sticky = $(".sticky"); -// $(window).on("scroll", function () { -// var scrollTop = $(window).scrollTop(); -// if(scrollTop > 0){ -// $(sticky).addClass("fixed"); -// $(body).addClass("f-topbar-fixed"); -// } -//// if(scrollTop == 0){ -//// $(sticky).removeClass("fixed"); -//// $(body).removeClass("f-topbar-fixed"); -//// } -// }); + var body = $("body"); + var sticky = $(".sticky"); + $(window).on("scroll", function () { + var scrollTop = $(window).scrollTop(); + if(scrollTop > 0){ + $(sticky).addClass("fixed"); + $(body).addClass("f-topbar-fixed"); + } +// if(scrollTop == 0){ +// $(sticky).removeClass("fixed"); +// $(body).removeClass("f-topbar-fixed"); +// } + }); }); diff --git a/js/custom/pageSetup.js b/js/custom/pageSetup.js index 0a1fcba..398a7b7 100644 --- a/js/custom/pageSetup.js +++ b/js/custom/pageSetup.js @@ -41,18 +41,18 @@ $(document).ready(function () { this.title = $(this.element).find('img').attr('alt'); } }); -// var body = $("body"); -// var sticky = $(".sticky"); -// $(window).on("scroll", function () { -// var scrollTop = $(window).scrollTop(); -// if(scrollTop > 0){ -// $(sticky).addClass("fixed"); -// $(body).addClass("f-topbar-fixed"); -// } -//// if(scrollTop == 0){ -//// $(sticky).removeClass("fixed"); -//// $(body).removeClass("f-topbar-fixed"); -//// } -// }); + var body = $("body"); + var sticky = $(".sticky"); + $(window).on("scroll", function () { + var scrollTop = $(window).scrollTop(); + if(scrollTop > 0){ + $(sticky).addClass("fixed"); + $(body).addClass("f-topbar-fixed"); + } +// if(scrollTop == 0){ +// $(sticky).removeClass("fixed"); +// $(body).removeClass("f-topbar-fixed"); +// } + }); }); -- 2.17.1