Secure HTML5 Video Player
Script error in IE8 (7 posts)

  1. Andy Keith
    Posted 4 years ago #


    Thanks for a great plugin!

    In IE8, I'm getting a script error when displaying a video: "'null' is null or not an object". I read somewhere that this could be because the DOM is being modified before the page has finished loading, although this could be a red herring? The video still displays correctly, it's just that IE reports an error when the page is loaded.

    I've tried debugging the problem but didn't get very far. When the video is removed from the page, I don't get the error.

    It's working perfectly in IE9, Firefox, Chrome and Safari. Just IE8 which is causing a problem.

    Any ideas what might be causing this?

    Many thanks


  2. Sage Brownell
    Posted 4 years ago #

    I don't believe EI8 supports HTML5 at all.

  3. Andy Keith
    Posted 4 years ago #

    No you're right, but the plugin uses VideoJS which provides a Flash fallback for IE6-8. It's this fallback which is causing the script error (I think!)...

  4. Sage Brownell
    Posted 4 years ago #

    You may want to ask VideoJS then...have you seen this?

  5. Andy Keith
    Posted 4 years ago #

    Yes, I came across that thread before posting. Someone mentioned changing the 'flashvars' attribute, but since the plugin handles those settings when displaying the videos, I thought it was worth raising here to see if there was a solution.

    It's a tricky one because there's several layers for me as a user of this plugin - there's the Secure HTML5 Video code, then there's VideoJS, then there's FlowPlayer. As the plugin is a 'black box', I've no idea where the problem lies!

  6. Sage Brownell
    Posted 4 years ago #

    I'm really sorry, but I can't help you then...it doesn't seem to be a problem with WordPress...I would dig deeper on the VideoJS site and maybe contact their support if I were you. Sorry I couldn't be of more help and I wish you luck on your searching.

  7. Andy Keith
    Posted 4 years ago #

    I've managed to fix the problem. There's a well reported issue with Flowplayer (used by this plugin as a Flash fallback):


    By adding an ID attribute to the <object> tag used for the Flash fallback in IE7/8, the problem goes away. So line 539 in /secure-html5-video-player/functions.php becomes:

    $video_tag .= "<object id='flash-fallback' class='vjs-flash-fallback'...etc

    Hope that helps..

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Secure HTML5 Video Player
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic