[wp-trac] [WordPress Trac] #38172: Enable Video Headers in Custom Headers
WordPress Trac
noreply at wordpress.org
Thu Oct 27 21:50:58 UTC 2016
#38172: Enable Video Headers in Custom Headers
-------------------------------------+-------------------------------------
Reporter: davidakennedy | Owner: joemcgill
Type: task (blessed) | Status: closed
Priority: normal | Milestone: 4.7
Component: Themes | Version: trunk
Severity: normal | Resolution: fixed
Keywords: has-patch ui-feedback | Focuses: ui, accessibility,
ux-feedback dev-feedback has- | javascript
screenshots |
-------------------------------------+-------------------------------------
Changes (by joemcgill):
* status: accepted => closed
* resolution: => fixed
Comment:
In [changeset:"38985"]:
{{{
#!CommitTicketReference repository="" revision="38985"
Themes: Enable video in custom headers.
This adds the ability for themes to add support for videos in custom
headers
by passing `'video' => true` as an argument when adding theme support for
custom headers.
Custom video headers are managed through the “Header Visuals” (i.e.
“Header Image”)
panel in the Customizer where you can select a video from the media
library or set a
URL to an external video (YouTube for now) for use in custom headers.
This introduces several new functions:
`has_header_video()` – Check whether a header video is set or not.
`get_header_video_url()` – Retrieve header video URL for custom header.
`the_header_video_url()` – Display header video URL.
`get_header_video_settings()` – Retrieve header video settings.
`has_custom_header()` – Check whether a custom header is set or not.
`get_custom_header_markup()` – Retrieve the markup for a custom header.
`the_custom_header_markup()` – Print the markup for a custom header.
And a new file, `wp-includes/js/wp-custom-header.js` that handles loading
videos
in custom headers.
This also enables video headers in the Twenty Seventeen and Twenty
Fourteen themes.
Props davidakennedy, celloexpressions, bradyvercher, laurelfulford,
joemcgill.
Fixes #38172.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38172#comment:77>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list