[wp-trac] [WordPress Trac] #51761: Inconsistent displayed date in get_calendar()

WordPress Trac noreply at wordpress.org
Tue Jan 19 10:21:07 UTC 2021


#51761: Inconsistent displayed date in get_calendar()
-------------------------------------------------+-------------------------
 Reporter:  labbit                               |       Owner:  (none)
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
                                                 |  Review
Component:  Date/Time                            |     Version:
 Severity:  minor                                |  Resolution:
 Keywords:  needs-patch has-screenshots          |     Focuses:
  reporter-feedback                              |
-------------------------------------------------+-------------------------
Changes (by labbit):

 * type:  defect (bug) => enhancement
 * severity:  normal => minor


Comment:

 Hello,
 the plugin that caused the issue was ajax-event-calendar, doing this:

 {{{#!php

 function localize_plugin($page) {
         load_plugin_textdomain(AEC_NAME, false, AEC_NAME . '/locale/');
         $timezone = get_option('timezone_string');
         if ($timezone) {
                         date_default_timezone_set($timezone);
         } else {
                         // TODO: look into converting gmt_offset into
 timezone_string
                         date_default_timezone_set('UTC');
         }

         ...
 }

 }}}

 Anyway, if you substituted `date` with `gmdate` in that commit, I still
 believe you should subst `mktime` with `gmmktime`, too.

 Thanks for you support.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/51761#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list