From: Anthony Talarico Date: Mon, 2 Nov 2015 17:54:53 +0000 (-0500) Subject: min date for html5 not functioning properly X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=53061ff8f4add5169fd43c591eefaa562d4fb9cf;p=WP-Themes%2Fglmthemes%2Fbpla-theme.git min date for html5 not functioning properly --- diff --git a/js/app.js b/js/app.js index 03c598d..a2770d2 100644 --- a/js/app.js +++ b/js/app.js @@ -79,15 +79,9 @@ $(document).ready(function () { // $("#dateOff1").attr("min", requiredDate); $("#dateOff1").change(function () { - currentDate = this.value; - today = new Date(currentDate); - d = today.getDate() + 2; - m = today.getMonth() + 1; - y = today.getFullYear(); - requiredDate = y + '-' + m + '-' + d; - - + }); + $("dateOff1").validate(); // $("#date1").val(requiredDate); $("#date1").datepicker({ minDate: 2, diff --git a/js/custom/pageSetup.js b/js/custom/pageSetup.js index 64b5403..c61265d 100644 --- a/js/custom/pageSetup.js +++ b/js/custom/pageSetup.js @@ -70,15 +70,9 @@ $(document).ready(function () { // $("#dateOff1").attr("min", requiredDate); $("#dateOff1").change(function () { - currentDate = this.value; - today = new Date(currentDate); - d = today.getDate() + 2; - m = today.getMonth() + 1; - y = today.getFullYear(); - requiredDate = y + '-' + m + '-' + d; - - + }); + $("dateOff1").validate(); // $("#date1").val(requiredDate); $("#date1").datepicker({ minDate: 2, diff --git a/parts/off-canvas-menu.php b/parts/off-canvas-menu.php index 5eef5d7..803fd70 100644 --- a/parts/off-canvas-menu.php +++ b/parts/off-canvas-menu.php @@ -16,8 +16,8 @@ Book Now - - + +