From: <var...@us...> - 2021-01-04 08:55:28
|
Revision: 10222 http://sourceforge.net/p/phpwiki/code/10222 Author: vargenau Date: 2021-01-04 08:55:25 +0000 (Mon, 04 Jan 2021) Log Message: ----------- Better time and date formats: 24-hour time, day month year Modified Paths: -------------- trunk/lib/WikiTheme.php trunk/themes/Crao/themeinfo.php trunk/themes/Hawaiian/themeinfo.php trunk/themes/MacOSX/themeinfo.php trunk/themes/MonoBook/themeinfo.php trunk/themes/Portland/themeinfo.php trunk/themes/Sidebar/themeinfo.php trunk/themes/Wordpress/themeinfo.php trunk/themes/blog/themeinfo.php trunk/themes/shamino_com/themeinfo.php trunk/themes/wikilens/themeinfo.php Modified: trunk/lib/WikiTheme.php =================================================================== --- trunk/lib/WikiTheme.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/lib/WikiTheme.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -353,8 +353,8 @@ // http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_crt_strftime.2c_.wcsftime.asp // As a result, we have to use %d, and strip out leading zeros ourselves. - private $dateFormat = "%B %d, %Y"; - private $timeFormat = "%I:%M %p"; + private $dateFormat = "%d %B %Y"; + private $timeFormat = "%H:%M"; private $showModTime = true; /** @@ -407,7 +407,7 @@ } /** - * Format a date. + * Format a time. * * Any time zone offset specified in the users preferences is * taken into account by this method. @@ -1485,14 +1485,14 @@ * $this->setDateFormat("%x"); * $this->setTimeFormat("%X"); */ - //$this->setDateFormat("%B %d, %Y"); - //$this->setTimeFormat("%I:%M %p"); + //$this->setDateFormat("%d %B %Y"); + //$this->setTimeFormat("%H:%M"); /* * To suppress times in the "Last edited on" messages, give a * give a second argument of false: */ - //$this->setDateFormat("%B %d, %Y", false); + //$this->setDateFormat("%d %B %Y", false); /* * Custom UserPreferences: Modified: trunk/themes/Crao/themeinfo.php =================================================================== --- trunk/themes/Crao/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/Crao/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -85,14 +85,14 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - //$this->setDateFormat("%B %d, %Y"); - //$this->setTimeFormat("%I:%M %p"); + //$this->setDateFormat("%d %B %Y"); + //$this->setTimeFormat("%H:%M"); /* * To suppress times in the "Last edited on" messages, give a * give a second argument of false: */ - //$this->setDateFormat("%B %d, %Y", false); + //$this->setDateFormat("%d %B %Y", false); $this->setDateFormat("%A %e %B %Y"); // must not contain time //$this->setDateFormat("%x"); // must not contain time $this->setTimeFormat("%H:%M:%S"); Modified: trunk/themes/Hawaiian/themeinfo.php =================================================================== --- trunk/themes/Hawaiian/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/Hawaiian/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -110,7 +110,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - //$this->setDateFormat("%B %d, %Y"); // must not contain time + //$this->setDateFormat("%d %B %Y"); // must not contain time } } Modified: trunk/themes/MacOSX/themeinfo.php =================================================================== --- trunk/themes/MacOSX/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/MacOSX/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -176,8 +176,8 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%A, %B %d, %Y"); // must not contain time - $this->setTimeFormat("%I:%M:%S %p"); + $this->setDateFormat("%A, %d %B %Y"); // must not contain time + $this->setTimeFormat("%H:%M:%S"); } } Modified: trunk/themes/MonoBook/themeinfo.php =================================================================== --- trunk/themes/MonoBook/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/MonoBook/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -138,7 +138,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%B %d, %Y"); + $this->setDateFormat("%d %B %Y"); $this->setTimeFormat("%H:%M"); /* @@ -145,7 +145,7 @@ * To suppress times in the "Last edited on" messages, give a * give a second argument of false: */ - //$this->setDateFormat("%B %d, %Y", false); + //$this->setDateFormat("%d %B %Y", false); } } Modified: trunk/themes/Portland/themeinfo.php =================================================================== --- trunk/themes/Portland/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/Portland/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -124,7 +124,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%B %d, %Y", false); + $this->setDateFormat("%d %B %Y", false); } } Modified: trunk/themes/Sidebar/themeinfo.php =================================================================== --- trunk/themes/Sidebar/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/Sidebar/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -197,7 +197,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - //$this->setDateFormat("%B %d, %Y"); + //$this->setDateFormat("%d %B %Y"); /** * Custom UserPreferences: Modified: trunk/themes/Wordpress/themeinfo.php =================================================================== --- trunk/themes/Wordpress/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/Wordpress/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -123,7 +123,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%B %d, %Y", false); + $this->setDateFormat("%d %B %Y", false); } } Modified: trunk/themes/blog/themeinfo.php =================================================================== --- trunk/themes/blog/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/blog/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -183,8 +183,8 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - //$this->setDateFormat("%B %d, %Y"); - $this->setDateFormat("%A, %B %e, %Y"); // must not contain time + //$this->setDateFormat("%d %B %Y"); + $this->setDateFormat("%A, %e %B %Y"); // must not contain time $this->setTimeFormat("%H:%M:%S"); } } Modified: trunk/themes/shamino_com/themeinfo.php =================================================================== --- trunk/themes/shamino_com/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/shamino_com/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -122,7 +122,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%B %d, %Y"); + $this->setDateFormat("%d %B %Y"); $this->setTimeFormat("%H:%M"); /* @@ -129,7 +129,7 @@ * To suppress times in the "Last edited on" messages, give a * give a second argument of false: */ - //$this->setDateFormat("%B %d, %Y", false); + //$this->setDateFormat("%d %B %Y", false); } } Modified: trunk/themes/wikilens/themeinfo.php =================================================================== --- trunk/themes/wikilens/themeinfo.php 2021-01-03 15:23:36 UTC (rev 10221) +++ trunk/themes/wikilens/themeinfo.php 2021-01-04 08:55:25 UTC (rev 10222) @@ -105,7 +105,7 @@ * Do not include the server's zone (%Z), times are converted to the * user's time zone. */ - $this->setDateFormat("%B %d, %Y"); + $this->setDateFormat("%d %B %Y"); $this->setTimeFormat("%H:%M"); /* @@ -112,7 +112,7 @@ * To suppress times in the "Last edited on" messages, give a * give a second argument of false: */ - //$this->setDateFormat("%B %d, %Y", false); + //$this->setDateFormat("%d %B %Y", false); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |