cvs: smarty / NEWS /plugins function.html_select_date.php shared.make_timestamp.php

From: Date: Tue, 18 Jun 2002 14:16:00 +0000
Subject: cvs: smarty / NEWS /plugins function.html_select_date.php shared.make_timestamp.php
Groups: php.smarty.cvs 
Request: Send a blank email to php-smarty-cvs+get-141@lists.php.net to get a copy of this message
mohrt Tue Jun 18 10:16:00 2002 EDT Modified files: /smarty NEWS /smarty/plugins function.html_select_date.php shared.make_timestamp.php Log: corrected warnings in html_select_time function, made make timestamp always return a timestamp Index: smarty/NEWS diff -u smarty/NEWS:1.206 smarty/NEWS:1.207 --- smarty/NEWS:1.206 Tue Jun 11 16:06:34 2002 +++ smarty/NEWS Tue Jun 18 10:15:57 2002 @@ -1,3 +1,5 @@ + - fixed warnings with html_select_date and timestamp + functions (Monte) - added support for sub directory exlusion format (Monte) - added support for grouping by cache_id, compile_id and segments thereof (Monte) Index: smarty/plugins/function.html_select_date.php diff -u smarty/plugins/function.html_select_date.php:1.10 smarty/plugins/function.html_select_date.php:1.11 --- smarty/plugins/function.html_select_date.php:1.10 Tue May 21 15:41:34 2002 +++ smarty/plugins/function.html_select_date.php Tue Jun 18 10:15:58 2002 @@ -56,6 +56,7 @@ $field_order = 'MDY'; /* String printed between the different fields. */ $field_separator = "\n"; + $time = time(); extract($params); Index: smarty/plugins/shared.make_timestamp.php diff -u smarty/plugins/shared.make_timestamp.php:1.1 smarty/plugins/shared.make_timestamp.php:1.2 --- smarty/plugins/shared.make_timestamp.php:1.1 Thu Jan 31 15:49:40 2002 +++ smarty/plugins/shared.make_timestamp.php Tue Jun 18 10:15:58 2002 @@ -22,8 +22,11 @@ return $time; } - // can't decipher, just return it - return $string; + // couldn't recognize it, try to return a time + if ((int) $time > 0) + return (int) $time; + else + return time(); } /* vim: set expandtab: */

« previous php.smarty.cvs (#141) next »