Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

HTML5 Background Color


When using the following code, the flash version loads up with the Red background color, but the HTML5 player just stays black. Is there a way I can make this work properly? I've tried several iterations of config now with the same results every time.

<video id="TestVid" src="video.mp4" width="900" height="510" controls="controls"></video>
<script type="text/javascript">
jwplayer('TestVid').setup({
'screencolor': 'FF0000',
'modes': [
{type: 'html5'},
{type: 'flash', src: 'jw5.5/player.swf'}
]
});
</script>

5 Community Answers

Ethan Feldman

JW Player Support Agent  
0 rated :

The color variables are not supported in HTML5 mode.

JW Player

User  
0 rated :

I know they aren't directly supported, but after the HTML5 player is generated I am able to manually set the background color using Firebug or the Chrome inspector. Is this something that will hopefully be added in future versions?

Ethan Feldman

JW Player Support Agent  
0 rated :

Possibly.

JW Player

User  
0 rated :

You can set the bg with:

$('#jw-embedder-playlist-player>div').css('background-color', 'rgb(255, 255, 255)');

which kind of sucks for a settings UI, because the settings for the object conversion use a hex value (without the '#'), e.g. ffffff. You cannot override with:

$('#jw-embedder-playlist-player>div').css('background-color', '#ffffff');

Could you create the div to inherit the background-color css property from the video element? Or at least use the hex value for the inline CSS?

JW Player

User  
0 rated :

Have you tried setting wmode to transparent and then use a division element for you background color

This question has received the maximum number of answers.