[wp-trac] [WordPress Trac] #39695: Add preload headers in redirects

WordPress Trac noreply at wordpress.org
Sun Feb 26 22:48:31 UTC 2017


#39695: Add preload headers in redirects
----------------------------------------+------------------------------
 Reporter:  onnimonni                   |       Owner:
     Type:  enhancement                 |      Status:  new
 Priority:  normal                      |   Milestone:  Awaiting Review
Component:  HTTP API                    |     Version:
 Severity:  normal                      |  Resolution:
 Keywords:  has-patch needs-unit-tests  |     Focuses:
----------------------------------------+------------------------------
Changes (by johnbillion):

 * keywords:   => has-patch needs-unit-tests


Comment:

 I quite like this idea. The logic in
 `wp_maybe_add_redirect_preload_headers()` needs some tests though, so I
 recommend altering this function so it returns a URL instead of outputting
 the header directly. This means the function can have unit tests written
 against it, and the actual header can then be output in `wp_redirect()`.

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


More information about the wp-trac mailing list