最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

video player - Embed .mov file via 'Add Media' not working

programmeradmin0浏览0评论

I know since WP 3.6 we've been able to upload and embed various file formats and that the 'Add Media' button effectively implements the correct media embed shortcode for us.

I'm having a problem in WP4.0 using 'Add Media' to embed quicktime (.mov) files. The embed works fine for the other supported video MIME types but I'm not offered 'Embed Media Player' when I try adding a .mov file to a post.

See screen grabs/explanation:

See how .mov embed has reverted to a simple hyperlink (recorders) at this page

Does anyone have any suggestions as to why this is, or to a possible fix so I can embed .mov as easily as .mp4 - seems to be the preferred format of the client. For the moment we're having to manually add the [video] shortcode ourselves in the text editor.

How do I check that embed is supported/enabled for .mov?

I know since WP 3.6 we've been able to upload and embed various file formats and that the 'Add Media' button effectively implements the correct media embed shortcode for us.

I'm having a problem in WP4.0 using 'Add Media' to embed quicktime (.mov) files. The embed works fine for the other supported video MIME types but I'm not offered 'Embed Media Player' when I try adding a .mov file to a post.

See screen grabs/explanation:

See how .mov embed has reverted to a simple hyperlink (recorders) at this page

Does anyone have any suggestions as to why this is, or to a possible fix so I can embed .mov as easily as .mp4 - seems to be the preferred format of the client. For the moment we're having to manually add the [video] shortcode ourselves in the text editor.

How do I check that embed is supported/enabled for .mov?

Share Improve this question edited Oct 21, 2014 at 8:53 birgire 68.1k7 gold badges120 silver badges252 bronze badges asked Oct 17, 2014 at 15:27 DozzaDozza 411 gold badge1 silver badge2 bronze badges
Add a comment  | 

2 Answers 2

Reset to default 7

You can try the following:

/**
 * Add support for the QuickTime (.mov) video format.
 */
add_filter( 'wp_video_extensions', 
    function( $exts ) {
        $exts[] = 'mov';
        return $exts;
    }
);

to add the Embed Media Player support for the QuickTime video files.

The default supported video formats are:

mp4, m4v, webm, ogv, wmv, flv

Update:

When I test this I get the Embed Media Player option and following shortcode inserted into the post:

[video width="240" 
       height="180" 
       mov="http://example/wp-content/uploads/2014/10/video1.mov"][/video]

Similar for the .avi and .wmv extensions:

[video width="160" 
       height="120" 
       avi="http://example/wp-content/uploads/2014/10/video2.avi"][/video]


[video width="1280" 
       height="720" 
       wmv="http://example/wp-content/uploads/2014/10/video3.wmv"][/video]

Not very beautiful but work for me - just hartcode " type="video/mp4">

发布评论

评论列表(0)

  1. 暂无评论