[wp-trac] Re: [WordPress Trac] #136: Month changeover in Calendar
does not use gm offset
WordPress Trac
wp-trac at lists.automattic.com
Mon Jul 31 20:56:41 GMT 2006
#136: Month changeover in Calendar does not use gm offset
-----------------------------+----------------------------------------------
Reporter: anonymousbugger | Owner: matt
Type: defect | Status: reopened
Priority: normal | Milestone:
Component: General | Version: 2.0.4
Severity: minor | Resolution:
Keywords: calendar month |
-----------------------------+----------------------------------------------
Changes (by thermoman):
* resolution: fixed =>
* keywords: => calendar month
* version: => 2.0.4
* status: closed => reopened
Comment:
See http://wordpress.org/support/topic/13874
My calendar is 1 day ahead and i fixed it using this diff:
{{{
--- wp-includes/template-functions-general.php.orig 2006-07-31
22:55:03.000000000 +0200
+++ wp-includes/template-functions-general.php 2006-07-31
22:55:10.000000000 +0200
@@ -433,8 +433,8 @@
else
$thismonth = ''.zeroise(intval(substr($m,
4, 2)), 2);
} else {
- $thisyear = gmdate('Y', current_time('timestamp') +
get_settings('gmt_offset') * 3600);
- $thismonth = gmdate('m', current_time('timestamp') +
get_settings('gmt_offset') * 3600);
+ $thisyear = gmdate('Y', current_time('timestamp'));
+ $thismonth = gmdate('m', current_time('timestamp'));
}
$unixmonth = mktime(0, 0 , 0, $thismonth, 1, $thisyear);
}}}
--
Ticket URL: <http://trac.wordpress.org/ticket/136>
WordPress Trac <http://wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list