• I’ve been trying to make this extremely basic page template for videos

    <?php get_header(); ?>
    
    <video width="1280" height="720" controls>
    
    <source src="<?php echo get_post_meta($post->ID, 'webm', true); ?>" type="video/webm">
    
    <source src="<?php echo get_post_meta($post->ID, 'mp4', true); ?>" type="video/mp4">
    
    </video> 
    
    <?php get_footer(); ?>

    But it wasn’t working. I thought maybe it was a problem in the way I was calling for the custom field entry for the videos urls, but even when you directly code the url’s, you get an error saying “No video with supported MIME type found.”

    The code works fine a basic html page, so I assume it must be a problem with WordPress? Anybody know how to fix it?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator bcworkz

    (@bcworkz)

    WP filters out some embedment HTML, forcing you to use it’s internal system, which whitelists only certain services. The internal system works well most of the time. See Embeds, though it may be slightly out of date. While the embedment technique is still the same, I believe I read somewhere oEmbed is no longer used internally in v3.6.

    Thread Starter alanchrishughes

    (@alanchrishughes)

    Thanks @bcworkz

    I haven’t launched the live site yet but it seems the problem was the server didn’t yet recognize the “MIME type.” This seemed to fix the problem http://www.html5videoplayer.net/html5video/enable-html5-videos-wordpress-mp4-webm-ogg-mime-types-setup/

    Is there a fix for the problem you were talking about though? With html being filtered out?

    Moderator bcworkz

    (@bcworkz)

    I’m not sure. I believe it is part of the tinymce editor somehow. Not something I know much about, much less how to cleanly hack it. Further more, there may be other filters in the process to stymie your efforts.

    My inclination would be to figure out a way to work with the embedment system rather than try to fight it. It was implemented this way partly for security reasons. Like many security measures, it can be a PITA, but it’s in our best interest to work with it instead of trying to disable it.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Does WordPress Block HTML 5 Video?’ is closed to new replies.