Hi @SophiePeirce,
Thanks for writing in. Can you also try this code? Put it in the child’s functions.php.
function x_featured_video( $post_type = 'video' ) {
$entry_id = get_the_ID();
$stack = x_get_stack();
$aspect_ratio = get_post_meta( $entry_id, '_x_' . $post_type . '_aspect_ratio', true );
$m4v = get_post_meta( $entry_id, '_x_' . $post_type . '_m4v', true );
$ogv = get_post_meta( $entry_id, '_x_' . $post_type . '_ogv', true );
$embed = get_post_meta( $entry_id, '_x_' . $post_type . '_embed', true );
$fullwidth = ( in_array( 'x-full-width-active', get_body_class() ) ) ? true : false;
if ( $fullwidth ) {
$poster = wp_get_attachment_image_src( get_post_thumbnail_id( $entry_id ), 'entry-fullwidth', false );
} else {
$poster = wp_get_attachment_image_src( get_post_thumbnail_id( $entry_id ), 'entry', false );
}
if ( $embed != '' ) {
echo do_shortcode( '[x_video_embed type="' . $aspect_ratio . '" no_container="true" class="mvn"]' . stripslashes( wp_specialchars_decode( $embed, ENT_QUOTES ) ) . '[/x_video_embed]' );
} else {
echo do_shortcode( '[x_video_player m4v="' . $m4v . '" ogv="' . $ogv . '" poster="' . $poster[0] . '" type="' . $aspect_ratio . '" preload="metadata" hide_controls="false" autoplay="false" loop="false" muted="false" no_container="true" class="mvn" advanced_controls="true"]' );
}
}
If it does not work, can you provide us a login credential to your site in a secure note, so we can have a closer look?
Thanks!