[wp-trac] [WordPress Trac] #39072: Add gmt_offset as a REST API setting

WordPress Trac noreply at wordpress.org
Tue Mar 5 19:07:12 UTC 2019


#39072: Add gmt_offset as a REST API setting
------------------------------------------+-----------------------------
 Reporter:  jshreve                       |       Owner:  (none)
     Type:  defect (bug)                  |      Status:  new
 Priority:  normal                        |   Milestone:  Future Release
Component:  REST API                      |     Version:  4.7
 Severity:  normal                        |  Resolution:
 Keywords:  needs-unit-tests needs-patch  |     Focuses:  rest-api
------------------------------------------+-----------------------------

Comment (by nickylimjj):

 Replying to [comment:4 rmccue]:
 > Replying to [comment:3 jnylen0]:
 > > > currently we intend the settings endpoint to be used only for
 settings that can be updated
 > >
 > > My mistake about this part - sitting next to @jshreve and he pointed
 out that this is possible to update via wp-admin.
 >
 > Likely, the settings endpoint should expose the raw value (either unset
 or the manual timezone offset), and the site info can expose the derived
 value (which will always have a value).


 I am picking this up. Could you @rmccue elaborate more on this? I am
 envisioning the interaction to be with `settings` endpoint to get the
 timezone and the `posts` endpoint to get the `date_gmt`, and calculating
 the local `time_posted` from there. Is this right?

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


More information about the wp-trac mailing list