From 057289f9790b03cbdd02fc42559e2dd106efd206 Mon Sep 17 00:00:00 2001 From: Nicolas Rochelemagne Date: Thu, 29 Mar 2012 15:41:04 -0500 Subject: [PATCH 7/9] dates from js calendar use 4 digits --- search.php | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/search.php b/search.php index 7318b98..b965064 100644 --- a/search.php +++ b/search.php @@ -347,7 +347,7 @@ function search_start() // Fetch the dates, if supplied $BeforeDay = $_REQUEST['BeforeDay'] ? $_REQUEST['BeforeDay'] : '31'; $BeforeMonth = $_REQUEST['BeforeMonth'] ? $_REQUEST['BeforeMonth'] : '12'; - $BeforeYear = $_REQUEST['BeforeYear'] ? $_REQUEST['BeforeYear'] : date('y'); + $BeforeYear = $_REQUEST['BeforeYear'] ? $_REQUEST['BeforeYear'] : date('Y'); $AfterDay = $_REQUEST['AfterDay'] ? $_REQUEST['AfterDay'] : '01'; $AfterMonth = $_REQUEST['AfterMonth'] ? $_REQUEST['AfterMonth'] : '01'; @@ -360,12 +360,12 @@ function search_start() $AfterMonth = $month[$AfterMonth] ? $month[$AfterMonth] : 'Jan'; // Don't specify a date if the user has selected the default values - $before = "$BeforeDay-$BeforeMonth-20$BeforeYear"; + $before = "$BeforeDay-$BeforeMonth-$BeforeYear"; if ( $before == "31-Dec-2009") $before = ''; // Don't specify a date if the user has selected the default values - $after = "$AfterDay-$AfterMonth-20$AfterYear"; + $after = "$AfterDay-$AfterMonth-$AfterYear"; if ($after == "01-Jan-2000") { $after = ""; -- 1.7.5