[wp-trac] [WordPress Trac] #51293: Add $option Parameter to wp_send_json, wp_send_json_success and wp_send_json_error

WordPress Trac noreply at wordpress.org
Tue Oct 20 15:54:58 UTC 2020


#51293: Add $option Parameter to wp_send_json, wp_send_json_success and
wp_send_json_error
------------------------------+-----------------------------
 Reporter:  eroraghav         |       Owner:  SergeyBiryukov
     Type:  feature request   |      Status:  closed
 Priority:  normal            |   Milestone:  5.6
Component:  General           |     Version:  5.5.1
 Severity:  normal            |  Resolution:  fixed
 Keywords:  has-patch commit  |     Focuses:
------------------------------+-----------------------------
Changes (by SergeyBiryukov):

 * status:  reviewing => closed
 * resolution:   => fixed


Comment:

 In [changeset:"49235" 49235]:
 {{{
 #!CommitTicketReference repository="" revision="49235"
 General: Add `$options` parameter to JSON response functions:

 * `wp_send_json()`
 * `wp_send_json_success()`
 * `wp_send_json_error()`

 This allows for customizing the options passed to `json_encode()`.

 Props eroraghav, hareesh-pillai, garrett-eclipse.
 Fixes #51293.
 }}}

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


More information about the wp-trac mailing list