Order Now AdSolution Sign Up | Login » Bits on the Run Sign Up | Login »

Forums

/

IE error 'null' is null or not an object (JWplayer 5.4)

17 replies [Last post]
Reply

Hello,

I receive an error in Internet Explorer only (I'm using IE8) with an embedded video using the latest licensed version of JWplayer 5.4. I don't know whether it is the way I am calling JWplayer, but I do know that when I take out the JW code the message goes away. The video plays fine, but stupid IE is reporting a script error. All other browsers work fine.

http://www.projectbasedsolutions.co.uk/

Navigate to "Videos" pane and then open one of the videos, eg. "Conditional Formatting" from the turntable or links on the left.

The code I am using is:

<script type="text/javascript">
    jwplayer("videoContainer").setup({
        height: 480,
        width: 640,
image: "/assets/videos/iee_conditional_formatting.jpg",
levels: [
{file: "/assets/videos/iee_conditional_formatting.mp4"},
{file: "/assets/videos/iee_conditional_formatting.webm"},
{file: "/assets/videos/iee_conditional_formatting.ogv"}
],
        players: [
            { type: "html5" },
            { type: "flash", src: "/assets/includes/mediaplayer-5.4-licensed/player.swf" },
{ type: "download" }
        ],
plugins: {
gapro: { accountid: "XX-XXXXXXX-X" }
}
    });
</script>

Thanks in advance for any help.

Simon

Reply

If you don't use the ligthbox, do you get the error?

Reply

Hi Ethan,

Thanks for your very speedy response.

Hmm, no: if I remove the lightbox, it does get rid of the error. If you refresh that site and go back to videos, I have a test page in place. It is playing without the error.

So is it likely that lightbox and the JWplayer instance are not playing very nicely together? I appreciate this isn't really your problem now (!) but anything immediately that you can think of that springs to mind for me to look into? The lightbox functionality uses jQuery if that makes any difference.

Plus I had the HTML5 beta working fine on another nearly identical site, complete with the same lightbox script. But then that was using the video tag method rather than the javascript method...

Reply
Reply

This is great to know about the JWbox and opening another Pandora's box for me ;-)

gonna check this out

Reply

Hi again,

I've had some time to revisit this now. I don't think I will be able to use your lightbox function, Ethan. I am pulling the lightbox content in via AJAX - the only option possible with yours seems to be by pulling hidden inline content into the lightbox??

I have managed to get this error message out of Firebug:
document.getElementById(i.id) is null
var jwplayer=function(a){return jwplay....skin,c(i,g,h))}return j}})(jwplayer);

And Chrome is reporting:
Uncaught TypeError: Cannot call method 'setup' of null
jwplayer.js:1Uncaught TypeError: Cannot set property 'onmousemove' of null

That is apparently what is causing the problem. Any other ideas for me to try?

Reply

Can you provide a link?

Reply

Hi Ethan,

Yes, it was the same website as OP:
http://www.projectbasedsolutions.co.uk/

Navigate to "Videos" pane and then open one of the videos, eg. "Conditional Formatting" from the turntable or links on the left.

Thanks,
Simon

Reply

Hi Simon,

I think it might be an issue of your own lighbox. Why can't you use ours?

Best,
-Ethan

Reply

Hi There,

I had the same issue and i use Fancybox to load the video.
If you have a parameter "'type' : 'iframe'" just remove that and the video will work fine :)

The fancybox solution for LongTail looks great, but sometimes we don't want to use multiple library for one function.

I hope this will help you out who had the same problem.

Reply

Thanks for sharing!

Reply

HI
Am also getting the same error,only in IE ..
Can you please help me out in this ..
I have not used any lightbox.

Reply

@prsmod

link please?

Reply

@pramod - What version of the player are you using?

Reply

Hi Guys - I am having troubles on windows platform MAC is OK get javascript error 'null' is null or not an object stuckkkkk

http://38.96.15.39/flash.html

Can you guys help put me in the right direction??

Thanks

Reply

This works for me on Windows.

Reply

hmmm.. this is rendered in the "quirks mode" and as a result, strange things will happen.

I suggest that you put in place a doctype.

In IE9, I cannot even get it to show and IE or "Internet Exploder" is the worst offender when it is rendering a page in the "quirks mode".

In fact, each browser handle it(quirks mode) differently.

Reply

IE requires the page to be fully formatted. You don't even have a <body> tag here. Try to put the player into a fully formatted HTML page, and things should be fine.

Post new comment

  • Allowed HTML tags: <code> <blockquote> <em> <strong> <strike> <ul> <li> <ol>
  • You may post code using <code>...</code> .
  • Lines and paragraphs break automatically.
  • Web page addresses and e-mail addresses turn into links automatically.

More information about formatting options