[geeklog-cvs] geeklog: Fixed advanced search not using start and end dates (re...

geeklog-cvs at lists.geeklog.net geeklog-cvs at lists.geeklog.net
Sat Jul 4 12:31:37 EDT 2009


details:   http://project.geeklog.net/cgi-bin/hgweb.cgi/rev/46ded8077a9b
changeset: 7166:46ded8077a9b
user:      Dirk Haun <dirk at haun-online.de>
date:      Sat Jul 04 18:31:27 2009 +0200
description:
Fixed advanced search not using start and end dates (really this time; bug #0000924, patch provided by dengen)

diffstat:

 public_html/docs/history        |  2 ++
 system/classes/search.class.php |  4 ++--
 2 files changed, 4 insertions(+), 2 deletions(-)

diffs (33 lines):

diff -r 9248eaefde1c -r 46ded8077a9b public_html/docs/history
--- a/public_html/docs/history	Sat Jul 04 17:31:22 2009 +0200
+++ b/public_html/docs/history	Sat Jul 04 18:31:27 2009 +0200
@@ -11,6 +11,8 @@
 + Comment moderation and editable comments, by Jared Wenerd
 
 Changes since 1.6.0rc1:
+- Fixed advanced search not using start and end dates (bug #0000924, patch
+  provided by dengen)
 - Fixed auto-detection of table prefix during migration when the SQL dump
   contained CREATE TABLE IF NOT EXISTS requests (bug #0000922) [Dirk]
 - When an error occurs in bigdump.php (during migration) send the user back to
diff -r 9248eaefde1c -r 46ded8077a9b system/classes/search.class.php
--- a/system/classes/search.class.php	Sat Jul 04 17:31:22 2009 +0200
+++ b/system/classes/search.class.php	Sat Jul 04 18:31:27 2009 +0200
@@ -371,7 +371,7 @@
                 $DE = explode($delim, $this->_dateEnd);
                 $startdate = mktime(0,0,0,$DS[1],$DS[2],$DS[0]);
                 $enddate = mktime(23,59,59,$DE[1],$DE[2],$DE[0]);
-                $sql .= "AND (UNIX_TIMESTAMP(date) BETWEEN '{$this->_dateStart}' AND '{$this->_dateEnd}') ";
+                $sql .= "AND (UNIX_TIMESTAMP(date) BETWEEN '$startdate' AND '$enddate') ";
             }
         }
         if (!empty($this->_topic)) {
@@ -432,7 +432,7 @@
                 $DE = explode($delim, $this->_dateEnd);
                 $startdate = mktime(0,0,0,$DS[1],$DS[2],$DS[0]);
                 $enddate = mktime(23,59,59,$DE[1],$DE[2],$DE[0]);
-                $sql .= "AND (UNIX_TIMESTAMP(c.date) BETWEEN '{$this->_dateStart}' AND '{$this->_dateEnd}') ";
+                $sql .= "AND (UNIX_TIMESTAMP(c.date) BETWEEN '$startdate' AND '$enddate') ";
             }
         }
         if (!empty($this->_topic)) {



More information about the geeklog-cvs mailing list