-
Notifications
You must be signed in to change notification settings - Fork 1
/
watch.php
39 lines (32 loc) · 1.13 KB
/
watch.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
<?php
require_once("includes/header.php");
require_once("includes/classes/VideoPlayer.php");
require_once("includes/classes/VideoInfoSection.php");
require_once("includes/classes/Comment.php");
require_once("includes/classes/CommentSection.php");
if(!isset($_GET["id"])){
echo "No url passed into page";
exit();
}
$video = new Video($con, $_GET["id"], $userLoggedInObj);
$video->incrementViews();
?>
<script src="assets/js/videoPlayerActions.js"></script>
<script src="assets/js/commentActions.js"></script>
<div class="watchLeftColumn">
<?php
$videoPlayer = new VideoPlayer($video);
echo $videoPlayer->create(true);
$videoInfoSection = new VideoInfoSection($con, $video, $userLoggedInObj);
echo $videoInfoSection->create();
$commentSection = new CommentSection($con, $video, $userLoggedInObj);
echo $commentSection->create();
?>
</div>
<div class="suggestions">
<?php
$videoGrid = new VideoGrid($con, $userLoggedInObj);
echo $videoGrid->create(null, null, false);
?>
</div>
<?php require_once("includes/footer.php"); ?>