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

Forums

/

JW Emebedder - JS error on setup

6 replies [Last post]
Reply

Hello, everyone.

I tried using JWembedder as follows

jwplayer('videoContainer').setup({
flashplayer: "/flashplayer/jwplayer/player.swf",
height: 270,
width: 480,
file: 'http://10.10.10.185/myvid.mp4'
});

But it doesn't embed the swf file and show the following message (Chrome):

Uncaught TypeError: Object function (){return window.System.Type.getType(this)} has no method 'addEventListener'
on jwplayer.js line 1

The same error happened in IE.

I downloaded the following script (to trace the error):

http://developer.longtailvideo.com/trac/browser/tags/mediaplayer-5.8/js/bin-debug/jwplayer.js

The stack trace is:
jwplayer.plugins.pluginloader.load - jwplayer.js:2262
jwplayer.embed - jwplayer.js:3017
jwplayer.api.setup - jwplayer.js:2605
wcJWPlayer._initializePlayer (my code)

Do you have any ideas?

thanks in advance.

Reply

Can you provide a link ?

Reply

I made an isolated example with only JwEmbedder and Mootools, and it worked fine.

It looks like something in my website is conflicting with JwEmbedder.

Now I'm going to try using swfobject.

Reply

Ok, with swfobject worked fine.

I also called jwplayer function to acquire the API stuff and it worked.

thank you.

Reply

np

Reply

Hey Ethan, now I got to make jwplayer.setup work (to switch to Video Tag automatically).

I found that jwplayer.plugins.pluginloader.load method loops the content of the config object in order to load plugins. The problem is that the Javascript Framework I'm using adds some methods to the Object prototype, and it messes with this process.

I changed many parts of the jwembedder script but I had no success. Probably there are many other places with the same looping technique that conflicts with the framework.

Unfortunately I will not be able to use JWPlayer for HTML5 VideoTag due to this issue.

I suggest to LongTail dev people to revise jwembedder to work alongside with any framework (specially with those that changes the Object prototype).

thanks in advance.

Reply

Can you provide any example of this error so I can actually debug it properly?

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