forked from Japnime/Facebook-Stream-Player
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathview.php
45 lines (45 loc) · 1.33 KB
/
view.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
include "core.php";
if($_GET['url'] != ""){
$flink = $_GET['url'];
$fdata = facebookstream($flink);
}
?>
<!DOCTYPE html>
<html>
<head>
<title>VideoJS Player</title>
<link rel="stylesheet" href="./template_view.css">
<link rel="stylesheet" href="./function_view.css">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<video id='video' class="video-js vjs-fluid vjs-16-9 vjs-big-play-centered" controls preload="auto" width="640" height="264" data-setup='{}'></video>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<script src="./script_view.js"></script>
<script src="./switch_view.js"></script>
<script>
videojs('video', {
controls: true,
fluid: true,
plugins: {
videoJsResolutionSwitcher: {
default: 'low',
dynamicLabel: true
}
}
}, function(){
var player = this;
window.player = player
player.updateSrc([
<?php
echo $fdata
?>
])
player.on('resolutionchange', function(){
console.info('Source changed to %s', player.src())
})
})
</script>
</body>
</html>