[wp-trac] [WordPress Trac] #38633: get_header_image_tag() doesn't always return the correct image
WordPress Trac
noreply at wordpress.org
Thu Nov 3 12:36:02 UTC 2016
#38633: get_header_image_tag() doesn't always return the correct image
------------------------------+------------------------
Reporter: bradyvercher | Owner: joemcgill
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.7
Component: Themes | Version:
Severity: normal | Resolution: fixed
Keywords: has-patch commit | Focuses:
------------------------------+------------------------
Changes (by joemcgill):
* status: reviewing => closed
* resolution: => fixed
Comment:
In [changeset:"39121"]:
{{{
#!CommitTicketReference repository="" revision="39121"
Themes: Improve reliability of URL used in `get_header_image_tag()`.
`get_header_image_tag()` relies on the data returned by
`get_custom_header()`
to build the attributes for the header `<img>` element. However,
`get_custom_header()` relies on data from the `header_image_data` theme
mod rather than the `header_image` theme mod that `get_header_image()`
uses.
This can create inconsistencies when no header image is set, but a theme
supports a default header image.
This fixes the issue by making `get_custom_image_tag()` rely on the URL
returned by `get_header_image()` instead.
Props bradyvercher.
Fixes #38633.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38633#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list