4 <body onload=
"loadCookieAndReferer()">
8 <script src=../../media-resources/video-test.js
></script>
9 <script src=../../media-resources/media-file.js
></script>
11 function loadCookieAndReferer () {
12 var movie
= findMediaFile('video', 'test');
13 var type
= mimeTypeForExtension(movie
.split('.').pop());
14 var frame
= document
.createElement('iframe');
17 frame
.addEventListener('load', function () {
18 source
= document
.getElementById('source');
19 source
.src
= 'http://127.0.0.1:8000/media/resources/video-referer-check-referer.php?name=' + movie
+ '&type=' + type
;
22 waitForEventAndFail('error');
23 waitForEventAndEnd('canplay');
27 frame
.src
= "data:text/html,<b>test</b>";
28 document
.body
.appendChild(frame
);
31 Tests that the media player will send the relevant referer when requesting the media file.
<br/>