
JW Player is requesting HTML page as image
JWPlayer seems to be requesting the page the video is embedded in itself as an image. Can anyone explain why this is going on, or, more importantly, how to stop it?
This is causing problems for our form submissions, which use a CSRF token in the form HTML to guarantee same-site submissions. However, the CSRF token, server-side, gets refreshed every time the page is called, making the client-side CSRF token in the form expire, making the form fail.
To see the strange JW Player behavior, go here in chrome with the network console open:
https://answersingenesis.org/media/video/evolution/lucy-shes-no-lady/
Filter the network calls by "Img" types only.
Chrome is a little quirky about what code gets blamed as the initiator (hit refresh a few times and the initiator may change), but sometimes it blames JW Player, and this problem happens on every page on this site that has JW Player on it that I have tested, and no pages without JW Player, so I think the player is the culprit.
I am using JWPlayer 6.12. Here is all the relevant code I think:
<video id="my-video" src="https://assets.answersingenesis.org/vid/ondemand/lucy-shes-no-lady.mp4"
poster="https://assets.answersingenesis.org/img/mediafile/preview_image/lucy-shes-no-lady.jpg"
controls="controls" analytic="Lucy—She’s No Lady" preload="none" width="100%">
<a href="https://assets.answersingenesis.org/vid/ondemand/lucy-shes-no-lady.mp4" target="_blank" title="Lucy—She’s No Lady">
<img src="https://assets.answersingenesis.org/img/mediafile/preview_image/lucy-shes-no-lady.jpg" alt="Lucy—She’s No Lady" border="0" />
</a>
</video>
<script>
jwplayer('my-video').setup(
{
"file": 'https://assets.answersingenesis.org/vid/ondemand/lucy-shes-no-lady.mp4',
"controlbar": 'bottom',
"image": 'https://assets.answersingenesis.org/img/mediafile/preview_image/lucy-shes-no-lady.jpg',
"type": 'mp4',
"width": '100%',
"aspectratio": '16:9',
"menu": false,
"skin": 'https://assets.answersingenesis.org/lib/js/jwplayer/skins/aig-2.0/aig.xml',
"controlbar.idlehide": true
});
</script>
Thanks for any help you can offer!