Adding Featured Video to Minimum Homepage

Community Forums Forums General Discussion Adding Featured Video to Minimum Homepage

This topic is: not resolved

This topic contains 1 reply, has 2 voices, and was last updated by  Jen Baumann 2 years, 1 month ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #10000


    Does anyone have a code snippet to share that I could add a video area on the homepage of the Minimum 2.0 theme in place of the Featured Image? I want to have a video that is the same 1600×600 size of that image. Would even be nice if it was a widget. Not sure.



    Jen Baumann

    You can pretty much follow Brian’s add a widget tutorial here to register the widget:

    You’ll have to do something like this to change the function in functions.php to include it:

    /** Add the featured image section */
    add_action( ‘genesis_after_header’, ‘minimum_featured_image’ );
    function minimum_featured_image() {
    	if ( is_home() ) {
    		   genesis_widget_area( ‘welcome-text’, array(
                           ‘before’ => ‘<div class="welcome-text widget-area">’,
                        ) );
    	elseif ( is_singular( array( ‘post’, ‘page’ ) ) && has_post_thumbnail() ){
    		echo ‘<div id="featured-image">';
    		echo get_the_post_thumbnail($thumbnail->ID, ‘header’);
    		echo ‘</div>';

    Plus whatever css you need.

    Note that code didn’t paste well so pay attention to the function already in your file.

    If you need technical support for your theme please file a ticket.

    The forums are community based. Staff only monitors the forum for issues relating to the forum itself and to redirect users to where they need to go.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.