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

JWPlayer in a Hidden Div


Hello,

I am trying to embed the JW Player in a hidden div and have it setup before the div gets visible.
However, JW Player will throw an error during the setup process if it is not in the visible div.

Is there any way to work around this issue?

My main issue is that it takes quite a time to setup the JW player that it is not smooth user experience to setup the player based on the user's action. I would like to have everything ready in advance.

It would even help a lot if I can at least pre-populate the frame of the player as the placeholder.

Thank you very much!

1 Community Answers

Todd

JW Player Support Agent  
0 rated :

Interesting. I’ve never tested our player in hidden divs before.

My suggestion would be to set up the player right away, but set the height and width to 0 when you first call jwplayer().setup(). Then you can resize the player to the desired size based on the user’s action. This way your div does not need to be hidden.

This question has received the maximum number of answers.