2

I am using latest version of JWPlayer and it shows a blank space when open the page with the video. The weird part is that when I refresh it twice/thrice, it works fine.

But it almost never works the first time the page opens.

This the error it shows in the console :-

Error handling "jwplayerReady" event listener [0]: SyntaxError: Failed to execute
'insertRule' on 'CSSStyleSheet': Failed to parse the rule  '#5831ef82aa5f92337bd88fe0c8d54bec_display_button  { background-image:
 url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAA0CAYAAACHO2h8AAAA7ElEQ…
8thSpN0xvbts0lxeZb/ACrDeOgYYyVOWeinyp6gnWdW0Vft69cndg2ea8AAAAASUVORK5CYII=), 
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAA0CAYAAACQGfi1AAAAZUlEQ…
v6Y0rIAygi5D8UjUUjA/aAyZwwOPIP2mMKRd9bdM79KAVee0AqrmZ58iQAAAAASUVORK5CYII=), 
url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAA0CAYAAACHO2h8AAAA8klEQ…
ZFjXwb55x8WtyKGtGRUpZCcLR7dzJ+B0iSy03DisYEQo0nc8B4p9SUlywAAAAASUVORK5CYII=); 
background-position: left,center,right; background-repeat: no-repeat; padding: 0 18px 0 18px;
 height: 52px; margin-top: -26px; }'. function (b){l.playerReady(b);a.css.unblock(d.id)} 

Any idea why this is happening?

Thanks.

Milad Rashidi
  • 1,296
  • 4
  • 22
  • 40
Steve
  • 2,546
  • 8
  • 49
  • 94
  • Please provide a link. – emaxsaun May 06 '14 at 16:30
  • Could you check the source in the console before passing it to jwplayer setup, check if the source is working correctly. Also, it would be helpful if you provide any link or jwplayer setup code which you are using to run this – Hitesh May 12 '14 at 03:59
  • Also check the answer evilom gave and check if your container div ID starts with a numerical character. – Hitesh May 12 '14 at 04:02

1 Answers1

3

In my case, it happens when my container div ID starts with a numerical character.

jwplayer("2someID").setup({
        file: fileURL,
        image: imgURL
    });     

see my example in this jsFiddle
try changing the div container id with a non-numeric character.

Check this link for more information

Hitesh
  • 4,098
  • 11
  • 44
  • 82
evilom
  • 573
  • 6
  • 19
  • evilom : great observation (y) !!! i would like to know how did you find this might be cause of error – Hitesh May 12 '14 at 04:07
  • I am adding one helpful link : http://www.maxdesign.com.au/articles/naming-ids-with-numbers/ in your answer – Hitesh May 12 '14 at 04:08
  • 1
    hitesh: Thanks! I am using multiple JW instances on a single page with randomly generated div IDs. Some of my IDs starts with a number and these divs causes the error when binding JW to them. – evilom May 12 '14 at 08:29