-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
107 lines (96 loc) · 5.19 KB
/
index.html
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CND Movie Trailer DB</title>
<!-- Bootstrap 3 -->
<link rel="stylesheet" href="https://netdna.bootstrapcdn.com/bootstrap/3.1.0/css/bootstrap.min.css">
<link rel="stylesheet" href="https://netdna.bootstrapcdn.com/bootstrap/3.1.0/css/bootstrap-theme.min.css">
<link href="https://fonts.googleapis.com/css?family=Raleway|Saira+Semi+Condensed" rel="stylesheet">
<script src="http://code.jquery.com/jquery-1.10.1.min.js"></script>
<script src="https://netdna.bootstrapcdn.com/bootstrap/3.1.0/js/bootstrap.min.js"></script>
<link rel="stylesheet" type="text/css" href="style.css">
<script type="text/javascript" charset="utf-8">
// Pause the video when the modal is closed
$(document).on('click', '.hanging-close, .modal-backdrop, .modal', function (event) {
// Remove the src so the player itself gets removed, as this is the only
// reliable way to ensure the video stops playing in IE
$("#trailer-video-container").empty();
});
// Start playing the video whenever the trailer modal is opened
$(document).on('click', '.movie-tile', function (event) {
var trailerYouTubeId = $(this).attr('data-trailer-youtube-id')
var sourceUrl = 'http://www.youtube.com/embed/' + trailerYouTubeId + '?autoplay=1&html5=1';
$("#trailer-video-container").empty().append($("<iframe></iframe>", {
'id': 'trailer-video',
'type': 'text-html',
'src': sourceUrl,
'frameborder': 0
}));
});
// Animate in the movies when the page loads
$(document).ready(function () {
$('.movie-tile').hide().first().show("fast", function showNext() {
$(this).next("div").show("fast", showNext);
});
});
</script>
</head>
<body>
<!-- Trailer Video Modal -->
<div class="modal" id="trailer">
<div class="modal-dialog">
<div class="modal-content">
<a href="#" class="hanging-close" data-dismiss="modal" aria-hidden="true">
<img src="https://lh5.ggpht.com/v4-628SilF0HtHuHdu5EzxD7WRqOrrTIDi_MhEG6_qkNtUK5Wg7KPkofp_VJoF7RS2LhxwEFCO1ICHZlc-o_=s0#w=24&h=24"/>
</a>
<div class="scale-media" id="trailer-video-container">
</div>
</div>
</div>
</div>
<!-- Main Page Content -->
<div class="container">
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<a class="navbar-brand" href="#">CND Movie Trailer DB</a>
</div>
</div>
</div>
</div>
<div class="container wrap zoom">
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="dU7OqGCIcak" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/commons/thumb/1/18/Eraserhead.jpg/220px-Eraserhead.jpg" width="220" height="342"></figure>
<h2>Eraserhead</h2>
</div>
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="_Ov8yLJkknY" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/en/thumb/c/c2/Original_Rocky_Horror_Picture_Show_poster.jpg/220px-Original_Rocky_Horror_Picture_Show_poster.jpg" width="220" height="342"></figure>
<h2>Rocky Horror Picture Show</h2>
</div>
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="EqYiSlkvRuw" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/en/thumb/6/67/Pan%27s_Labyrinth.jpg/220px-Pan%27s_Labyrinth.jpg" width="220" height="342"></figure>
<h2>Pan's Labyrinth</h2>
</div>
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="HUECWi5pX7o" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/en/thumb/5/53/Amelie_poster.jpg/220px-Amelie_poster.jpg" width="220" height="342"></figure>
<h2>Amelie</h2>
</div>
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="l1t8OZn_uhE" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/en/thumb/c/cb/Tucker-and-dale-vs-evil.jpg/220px-Tucker-and-dale-vs-evil.jpg" width="220" height="342"></figure>
<h2>Tucker & Dale vs Evil</h2>
</div>
<div class="col-sm-4 movie-tile text-center" data-trailer-youtube-id="jCOvhojlZzQ" data-toggle="modal" data-target="#trailer">
<figure><img src="https://upload.wikimedia.org/wikipedia/en/thumb/4/41/TOIL_poster.jpg/220px-TOIL_poster.jpg" width="220" height="342"></figure>
<h2>The One I Love</h2>
</div>
<footer class="text-center">
<p>Developed by <a href="http://www.CandiceDavidson.com">Candice Davidson</a></p>
<p>Background image by <a href="http://www.8backgrounds.com">8backgrounds.com</a><br>
Movie posters by <a href="https://www.wikipedia.org/">Wikipedia.org</a><br>
Movie trailers by <a href="https://www.youtube.com/">YouTube.com</a></p>
</footer>
</div>
</body>
</html>