New Video Header Option in Arcade

Header Video
When WordPress 4.7 was released, an option to use a header video instead of an image was added to the Customizer. Including the feature in a theme like Arcade seemed like a good idea but took me a while to finally get right.

Video Header Code

Including support for a video header is straightforward enough.

add_theme_support( 'custom-header', array(
 'video' => true,
) );

If you already declare support for a custom header you can just add 'video' => true, to the argument array.
In order for the new header video to appear in your theme, you need to place the the_custom_header_markup() function in the right spot. To get it working in Arcade took some custom CSS and a few changes to the core PHP code but I managed to figure it all out.

Header Media Section

With that in place, the Header Image section of the Customizer will now become the Header Media section, and a button to select/upload a video or include a YouTube link will appear.

Conclusion

If you already have a license for Arcade, be sure to update your copy to the latest release to play around with the new Header Video option. If not, head on over to Themes by bavotasan.com and purchase your copy today.
For more info on the Header Video functions check out the info page on Make WordPress Code.

Share this:

Email
Facebook
Twitter
Pinterest
Pocket

Premium Themes for WordPress

Looking for an easy-to-use Premium Theme for WordPress? Check out Themes by bavotasan.com and have your site up and running in no time.

Use this WordPress website builder to build powerful websites in no time for your or your clients.

WordPress Hosting

WP Engine – designed from the ground-up to support and enhance the workflow of web designers.

Bluehost – providing quality web hosting solutions since 1996.

About the author

Picture of Luke Perrie

Luke Perrie