[Jaws-commits] r9704 - trunk/jaws/html/gadgets/VisitCounter

afz at jaws-project.com afz at jaws-project.com
Sun Oct 19 03:44:35 UTC 2008


Author: afz
Date: 2008-10-19 03:44:35 +0000 (Sun, 19 Oct 2008)
New Revision: 9704

Modified:
   trunk/jaws/html/gadgets/VisitCounter/AdminHTML.php
Log:
fix using Y-m-d G:i:s instead of Y-m-d H:i:s in VisitCounter

Modified: trunk/jaws/html/gadgets/VisitCounter/AdminHTML.php
===================================================================
--- trunk/jaws/html/gadgets/VisitCounter/AdminHTML.php	2008-10-19 03:42:19 UTC (rev 9703)
+++ trunk/jaws/html/gadgets/VisitCounter/AdminHTML.php	2008-10-19 03:44:35 UTC (rev 9704)
@@ -201,6 +201,12 @@
         $tpl->SetBlock('visitcounter/item');
         $tpl->SetVariable('label', _t('VISITCOUNTER_STATS_FROM'));
         $date = $GLOBALS['app']->loadDate();
+
+        // fix using Y-m-d G:i:s instead of Y-m-d H:i:s in version 0.6.x
+        if (strlen($startDate) == 18) {
+            $startDate = substr_replace($startDate, '0', 11, 0);
+        }
+
         $tpl->SetVariable('value',  $date->Format($startDate,'Y-m-d'));
         $tpl->SetVariable('item_id', 'stats_from');
         $tpl->ParseBlock('visitcounter/item');



More information about the Jaws-commits mailing list