0

i think there is a problem with the video shortcode.

When i use [video src="" height="400"] the 400px height not work. The width work correctly but the height nothing.

Is it a bug?

1 Answer 1

2

It doesn't seems to be a bug, but it's designed like that only...

Have a look how height variable is being changed by other parameter to keep up the right video ratio based on the theme.

if ( 'video' === $type ) {
             $width = empty( $meta['width'] ) ? 640 : $meta['width'];
             $height = empty( $meta['height'] ) ? 360 : $meta['height'];
             $theme_height = round( ( $height * $theme_width ) / $width );
             $track['dimensions'] = array(
                     'original' => compact( 'width', 'height' ),
                     'resized' => array(
                             'width' => $theme_width,
                             'height' => $theme_height
                     )
             );
 }

Reference: Codex : Line No. 1092

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.