From: Anthony Talarico Date: Mon, 28 Dec 2015 19:12:09 +0000 (-0500) Subject: fixed syntax error X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=0a6ef6666e9a88a18cd7fd613ddbca2f8990d33b;p=WP-Themes%2Fmichsci.git fixed syntax error --- diff --git a/js/app.js b/js/app.js index 0c0b44d..eca8c71 100644 --- a/js/app.js +++ b/js/app.js @@ -23,7 +23,7 @@ $(document).ready(function () { "use strict"; document.cookie = "catView=grid"; // don't display products on the main "products page" - if ((window.location.href.indexOf("products") >= 0)){ + if ((window.location.href.indexOf("products-2") >= 0)){ $("#gridView").css("display", "none"); $("#listView").css("display", "none"); $("#grid").on("click", function (e) { @@ -36,7 +36,7 @@ $(document).ready(function () { }); } // hide product display initially - if ((window.location.href.indexOf("products/?michsci_category") >= 0)){ + if ((window.location.href.indexOf("products-2/?michsci_category") >= 0)){ $("#productsView").css("display", "inherit"); $("#categoriesView").css("display", "none"); $("#gridView").css("display", "inherit"); @@ -46,7 +46,7 @@ $(document).ready(function () { } // navigate back to products page if on single product page - if ((window.location.href.indexOf("products/?pagename") >= 0)) { + if ((window.location.href.indexOf("products-2/?pagename") >= 0)) { // $("#viewBtns").css("display", "none"); $("#grid").on("click", function (e) { document.cookie = "view=grid"; @@ -58,7 +58,7 @@ $(document).ready(function () { }); } // change output view from list to grid - if (!(window.location.href.indexOf("products/?pagename") >= 0)) { + if (!(window.location.href.indexOf("products-2/?pagename") >= 0)) { $("#grid").on("click", function (e) { document.cookie = "view=grid"; location.reload(); @@ -87,7 +87,7 @@ $(document).ready(function () { $("." + $(this).val()).show(); }); // hide products on front page, show all products if on products page - if($("#tagBox :checkbox:checked").length === 0 && !(window.location.href.indexOf("products/?michsci_category") >= 0)){ + if($("#tagBox :checkbox:checked").length === 0 && !(window.location.href.indexOf("products-2/?michsci_category") >= 0)){ $("#categoriesGridView").show(); $("#categoriesListView").show(); $("#gridView").css("display", "none"); diff --git a/js/custom/upcp.js b/js/custom/upcp.js index d40484b..79ddb6b 100644 --- a/js/custom/upcp.js +++ b/js/custom/upcp.js @@ -3,7 +3,7 @@ $(document).ready(function () { "use strict"; document.cookie = "catView=grid"; // don't display products on the main "products page" - if ((window.location.href.indexOf("products") >= 0)){ + if ((window.location.href.indexOf("products-2") >= 0)){ $("#gridView").css("display", "none"); $("#listView").css("display", "none"); $("#grid").on("click", function (e) { @@ -16,7 +16,7 @@ $(document).ready(function () { }); } // hide product display initially - if ((window.location.href.indexOf("products/?michsci_category") >= 0)){ + if ((window.location.href.indexOf("products-2/?michsci_category") >= 0)){ $("#productsView").css("display", "inherit"); $("#categoriesView").css("display", "none"); $("#gridView").css("display", "inherit"); @@ -26,7 +26,7 @@ $(document).ready(function () { } // navigate back to products page if on single product page - if ((window.location.href.indexOf("products/?pagename") >= 0)) { + if ((window.location.href.indexOf("products-2/?pagename") >= 0)) { // $("#viewBtns").css("display", "none"); $("#grid").on("click", function (e) { document.cookie = "view=grid"; @@ -38,7 +38,7 @@ $(document).ready(function () { }); } // change output view from list to grid - if (!(window.location.href.indexOf("products/?pagename") >= 0)) { + if (!(window.location.href.indexOf("products-2/?pagename") >= 0)) { $("#grid").on("click", function (e) { document.cookie = "view=grid"; location.reload(); @@ -67,7 +67,7 @@ $(document).ready(function () { $("." + $(this).val()).show(); }); // hide products on front page, show all products if on products page - if($("#tagBox :checkbox:checked").length === 0 && !(window.location.href.indexOf("products/?michsci_category") >= 0)){ + if($("#tagBox :checkbox:checked").length === 0 && !(window.location.href.indexOf("products-2/?michsci_category") >= 0)){ $("#categoriesGridView").show(); $("#categoriesListView").show(); $("#gridView").css("display", "none");