[wp-trac] [WordPress Trac] #63493: Timezone string doesn't return in REST API /wp-json/wp/v2/settings

WordPress Trac noreply at wordpress.org
Wed May 28 07:09:17 UTC 2025


#63493: Timezone string doesn't return in REST API /wp-json/wp/v2/settings
-------------------------------------------------+-------------------------
 Reporter:  phakphumvis                          |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
                                                 |  Review
Component:  REST API                             |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-test-info needs-     |     Focuses:  rest-api
  testing                                        |
-------------------------------------------------+-------------------------

Comment (by opurockey):

 `timezone` string return empty value if you set manual offsets value (
 e.g.: UTC -12 ) from `Settings->General->Timezone`. Better use
 `wp_timezone_string()` if timezone value is found empty when using the
 `/wp-json/wp/v2/settings` endpoint.

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


More information about the wp-trac mailing list