-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex2.php
73 lines (71 loc) · 2.46 KB
/
index2.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" name="viewport" content="width=device-width, initial-scale=1"/>
<link rel="stylesheet" type="text/css" href="css/bootstrap.css"/>
</head>
<body style="background-color: #509ddf;">
<nav class="navbar navbar-default">
<div class="container-fluid">
<a class="navbar-brand" href="index.php">Upload-Image</a>
<a class="navbar-brand" href="index.php"></a>
<a class="navbar-brand" href="index2.php">Upload-Video</a>
<a class="navbar-brand" href="index1.php">Upload-File</a>
</div>
</nav>
<div class="col-md-3"></div>
<div class="col-md-6 well">
<h3 class="text-primary"> Video Upload</h3>
<hr style="border-top:1px dotted #ccc;"/>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#form_modal"><span class="glyphicon glyphicon-plus"></span> Add Video</button>
<br /><br />
<hr style="border-top:3px solid #ccc;"/>
<?php
require 'conn.php';
$query = mysqli_query($conn, "SELECT * FROM `video` ORDER BY `video_id` ASC") or die(mysqli_error());
while($fetch = mysqli_fetch_array($query)){
?>
<div class="col-md-12">
<div class="col-md-4" style="word-wrap:break-word;">
<br />
<h4>Video Name</h4>
<h5 class="text-primary"><?php echo $fetch['video_name']?></h5>
</div>
<div class="col-md-8">
<video width="100%" height="240" controls>
<source src="<?php echo $fetch['location']?>">
</video>
</div>
<br style="clear:both;"/>
<hr style="border-top:1px groovy #000;"/>
</div>
<?php
}
?>
</div>
<div class="modal fade" id="form_modal" aria-hidden="true">
<div class="modal-dialog">
<form action="save_video.php" method="POST" enctype="multipart/form-data">
<div class="modal-content">
<div class="modal-body">
<div class="col-md-3"></div>
<div class="col-md-6">
<div class="form-group">
<label>Video File</label>
<input type="file" name="video" class="form-control-file"/>
</div>
</div>
</div>
<div style="clear:both;"></div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal"><span class="glyphicon glyphicon-remove"></span> Close</button>
<button name="save" class="btn btn-primary"><span class="glyphicon glyphicon-save"></span> Save</button>
</div>
</div>
</form>
</div>
</div>
<script src="js/jquery-3.2.1.min.js"></script>
<script src="js/bootstrap.js"></script>
</body>
</html>