@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | ?> |
176 | 176 | <?php |
177 | 177 | $stmt6 = $__db->prepare("SELECT * FROM favorite_video WHERE sender = :search ORDER BY id DESC LIMIT :pfirst, :pper"); |
178 | - $stmt6->bindParam(":search", $search); |
|
178 | + $stmt6->bindParam(":search", $search); |
|
179 | 179 | $stmt6->bindParam(":pfirst", $page_first_result); |
180 | 180 | $stmt6->bindParam(":pper", $results_per_page); |
181 | 181 | $stmt6->execute(); |
@@ -192,32 +192,32 @@ discard block |
||
192 | 192 | |
193 | 193 | <?php |
194 | 194 | while($video = $stmt6->fetch(PDO::FETCH_ASSOC)) { |
195 | - if($__video_h->video_exists($video['reciever'])) { |
|
196 | - $_video = $__video_h->fetch_video_rid($video['reciever']); |
|
197 | - $_video['video_responses'] = $__video_h->get_video_responses($_video['rid']); |
|
198 | - $_video['age'] = $__time_h->time_elapsed_string($_video['publish']); |
|
199 | - $_video['duration'] = $__time_h->timestamp($_video['duration']); |
|
200 | - $_video['views'] = $__video_h->fetch_video_views($_video['rid']); |
|
201 | - $_video['author'] = htmlspecialchars($_video['author']); |
|
202 | - $_video['title'] = htmlspecialchars($_video['title']); |
|
203 | - $_video['description'] = $__video_h->shorten_description($_video['description'], 50); |
|
204 | - |
|
205 | - if($_video['thumbnail'] == ".png" && $_video['filename'] == ".mp4") { |
|
206 | - $status = "Corrupted"; |
|
207 | - } else if($_video['visibility'] == "v") { |
|
208 | - $status = "Approved"; |
|
209 | - } else if($_video['visibility'] == "n") { |
|
210 | - $status = "Approved"; |
|
211 | - } else if($_video['visibility'] == "o") { |
|
212 | - $status = "Disapproved"; |
|
213 | - } else { |
|
214 | - $status = "Unknown"; |
|
215 | - } |
|
195 | + if($__video_h->video_exists($video['reciever'])) { |
|
196 | + $_video = $__video_h->fetch_video_rid($video['reciever']); |
|
197 | + $_video['video_responses'] = $__video_h->get_video_responses($_video['rid']); |
|
198 | + $_video['age'] = $__time_h->time_elapsed_string($_video['publish']); |
|
199 | + $_video['duration'] = $__time_h->timestamp($_video['duration']); |
|
200 | + $_video['views'] = $__video_h->fetch_video_views($_video['rid']); |
|
201 | + $_video['author'] = htmlspecialchars($_video['author']); |
|
202 | + $_video['title'] = htmlspecialchars($_video['title']); |
|
203 | + $_video['description'] = $__video_h->shorten_description($_video['description'], 50); |
|
204 | + |
|
205 | + if($_video['thumbnail'] == ".png" && $_video['filename'] == ".mp4") { |
|
206 | + $status = "Corrupted"; |
|
207 | + } else if($_video['visibility'] == "v") { |
|
208 | + $status = "Approved"; |
|
209 | + } else if($_video['visibility'] == "n") { |
|
210 | + $status = "Approved"; |
|
211 | + } else if($_video['visibility'] == "o") { |
|
212 | + $status = "Disapproved"; |
|
213 | + } else { |
|
214 | + $status = "Unknown"; |
|
215 | + } |
|
216 | 216 | |
217 | - if($_video['commenting'] == "a") |
|
218 | - $_video['commentstatus'] = "Commenting allowed"; |
|
219 | - else |
|
220 | - $_video['commentstatus'] = "Commenting disallowed"; |
|
217 | + if($_video['commenting'] == "a") |
|
218 | + $_video['commentstatus'] = "Commenting allowed"; |
|
219 | + else |
|
220 | + $_video['commentstatus'] = "Commenting disallowed"; |
|
221 | 221 | ?> |
222 | 222 | <tr style="margin-top: 5px;" id="videoslist"> |
223 | 223 | <td class="video-manager-left"> |
@@ -221,10 +221,11 @@ |
||
221 | 221 | $status = "Unknown"; |
222 | 222 | } |
223 | 223 | |
224 | - if($_video['commenting'] == "a") |
|
225 | - $_video['commentstatus'] = "Commenting allowed"; |
|
226 | - else |
|
227 | - $_video['commentstatus'] = "Commenting disallowed"; |
|
224 | + if($_video['commenting'] == "a") { |
|
225 | + $_video['commentstatus'] = "Commenting allowed"; |
|
226 | + } else { |
|
227 | + $_video['commentstatus'] = "Commenting disallowed"; |
|
228 | + } |
|
228 | 229 | ?> |
229 | 230 | <tr style="margin-top: 5px;" id="videoslist"> |
230 | 231 | <td class="video-manager-left"> |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | <?php $__user_h = new user_helper($__db); ?> |
11 | 11 | <?php $__db_h = new db_helper(); ?> |
12 | 12 | <?php $__time_h = new time_helper(); error_reporting(E_ERROR | E_PARSE); ?> |
13 | -<?php if(!isset($_SESSION['siteusername'])) { header("Location: /sign_in"); } ?> |
|
13 | +<?php if (!isset($_SESSION['siteusername'])) { header("Location: /sign_in"); } ?> |
|
14 | 14 | <!DOCTYPE html> |
15 | 15 | <html dir="ltr"> |
16 | 16 | <head> |
@@ -163,15 +163,15 @@ discard block |
||
163 | 163 | $stmt->execute(); |
164 | 164 | |
165 | 165 | $number_of_result = $stmt->rowCount(); |
166 | - $number_of_page = ceil ($number_of_result / $results_per_page); |
|
166 | + $number_of_page = ceil($number_of_result/$results_per_page); |
|
167 | 167 | |
168 | - if (!isset ($_GET['page']) ) { |
|
168 | + if (!isset ($_GET['page'])) { |
|
169 | 169 | $page = 1; |
170 | 170 | } else { |
171 | - $page = (int)$_GET['page']; |
|
171 | + $page = (int) $_GET['page']; |
|
172 | 172 | } |
173 | 173 | |
174 | - $page_first_result = ($page - 1) * $results_per_page; |
|
174 | + $page_first_result = ($page - 1)*$results_per_page; |
|
175 | 175 | ?> |
176 | 176 | <?php |
177 | 177 | $stmt6 = $__db->prepare("SELECT * FROM favorite_video WHERE sender = :search ORDER BY id DESC LIMIT :pfirst, :pper"); |
@@ -191,8 +191,8 @@ discard block |
||
191 | 191 | </tr> |
192 | 192 | |
193 | 193 | <?php |
194 | - while($video = $stmt6->fetch(PDO::FETCH_ASSOC)) { |
|
195 | - if($__video_h->video_exists($video['reciever'])) { |
|
194 | + while ($video = $stmt6->fetch(PDO::FETCH_ASSOC)) { |
|
195 | + if ($__video_h->video_exists($video['reciever'])) { |
|
196 | 196 | $_video = $__video_h->fetch_video_rid($video['reciever']); |
197 | 197 | $_video['video_responses'] = $__video_h->get_video_responses($_video['rid']); |
198 | 198 | $_video['age'] = $__time_h->time_elapsed_string($_video['publish']); |
@@ -202,19 +202,19 @@ discard block |
||
202 | 202 | $_video['title'] = htmlspecialchars($_video['title']); |
203 | 203 | $_video['description'] = $__video_h->shorten_description($_video['description'], 50); |
204 | 204 | |
205 | - if($_video['thumbnail'] == ".png" && $_video['filename'] == ".mp4") { |
|
205 | + if ($_video['thumbnail'] == ".png" && $_video['filename'] == ".mp4") { |
|
206 | 206 | $status = "Corrupted"; |
207 | - } else if($_video['visibility'] == "v") { |
|
207 | + } else if ($_video['visibility'] == "v") { |
|
208 | 208 | $status = "Approved"; |
209 | - } else if($_video['visibility'] == "n") { |
|
209 | + } else if ($_video['visibility'] == "n") { |
|
210 | 210 | $status = "Approved"; |
211 | - } else if($_video['visibility'] == "o") { |
|
211 | + } else if ($_video['visibility'] == "o") { |
|
212 | 212 | $status = "Disapproved"; |
213 | 213 | } else { |
214 | 214 | $status = "Unknown"; |
215 | 215 | } |
216 | 216 | |
217 | - if($_video['commenting'] == "a") |
|
217 | + if ($_video['commenting'] == "a") |
|
218 | 218 | $_video['commentstatus'] = "Commenting allowed"; |
219 | 219 | else |
220 | 220 | $_video['commentstatus'] = "Commenting disallowed"; |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | </div> |
261 | 261 | </center> |
262 | 262 | |
263 | - <?php for($page = 1; $page<= $number_of_page; $page++) { ?> |
|
263 | + <?php for ($page = 1; $page <= $number_of_page; $page++) { ?> |
|
264 | 264 | <button class="yt-uix-button yt-uix-button-default" onclick="ajax_fetch_videomanager(<?php echo $page; ?>)"><?php echo $page; ?></button> |
265 | 265 | <?php } ?> |
266 | 266 | |
@@ -306,7 +306,7 @@ discard block |
||
306 | 306 | </script> |
307 | 307 | |
308 | 308 | <?php |
309 | - if($stmt6->rowCount() == 0) { echo " |
|
309 | + if ($stmt6->rowCount() == 0) { echo " |
|
310 | 310 | <br>Welcome to your favorite vidoes page.<br> |
311 | 311 | You can add videos that you like and the video will be added here! |
312 | 312 | "; |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | <?php |
141 | 141 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
142 | 142 | $stmt->execute(); |
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
143 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | 144 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
145 | 145 | $video['duration'] = $__time_h->timestamp($video['duration']); |
146 | 146 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | <?php |
176 | 176 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
177 | 177 | $stmt->execute(); |
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
178 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | 179 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
180 | 180 | $video['duration'] = $__time_h->timestamp($video['duration']); |
181 | 181 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | <?php |
211 | 211 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
212 | 212 | $stmt->execute(); |
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
213 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | 214 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
215 | 215 | $video['duration'] = $__time_h->timestamp($video['duration']); |
216 | 216 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | <?php |
246 | 246 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
247 | 247 | $stmt->execute(); |
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
248 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | 249 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
250 | 250 | $video['duration'] = $__time_h->timestamp($video['duration']); |
251 | 251 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -280,7 +280,7 @@ discard block |
||
280 | 280 | <?php |
281 | 281 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
282 | 282 | $stmt->execute(); |
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
283 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | 284 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
285 | 285 | $video['duration'] = $__time_h->timestamp($video['duration']); |
286 | 286 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -138,16 +138,16 @@ discard block |
||
138 | 138 | </div> |
139 | 139 | <div class="browse-item-row ytg-box"> |
140 | 140 | <?php |
141 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
142 | - $stmt->execute(); |
|
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | - $video['author'] = htmlspecialchars($video['author']); |
|
148 | - $video['title'] = htmlspecialchars($video['title']); |
|
149 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | - ?> |
|
141 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
142 | + $stmt->execute(); |
|
143 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | + $video['author'] = htmlspecialchars($video['author']); |
|
148 | + $video['title'] = htmlspecialchars($video['title']); |
|
149 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | + ?> |
|
151 | 151 | <div class="browse-item yt-tile-default "> |
152 | 152 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
153 | 153 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -173,16 +173,16 @@ discard block |
||
173 | 173 | </div> |
174 | 174 | <div class="browse-item-row ytg-box"> |
175 | 175 | <?php |
176 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
177 | - $stmt->execute(); |
|
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | - $video['author'] = htmlspecialchars($video['author']); |
|
183 | - $video['title'] = htmlspecialchars($video['title']); |
|
184 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | - ?> |
|
176 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
177 | + $stmt->execute(); |
|
178 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | + $video['author'] = htmlspecialchars($video['author']); |
|
183 | + $video['title'] = htmlspecialchars($video['title']); |
|
184 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | + ?> |
|
186 | 186 | <div class="browse-item yt-tile-default "> |
187 | 187 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
188 | 188 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -208,16 +208,16 @@ discard block |
||
208 | 208 | </div> |
209 | 209 | <div class="browse-item-row ytg-box"> |
210 | 210 | <?php |
211 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
212 | - $stmt->execute(); |
|
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | - $video['author'] = htmlspecialchars($video['author']); |
|
218 | - $video['title'] = htmlspecialchars($video['title']); |
|
219 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | - ?> |
|
211 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
212 | + $stmt->execute(); |
|
213 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | + $video['author'] = htmlspecialchars($video['author']); |
|
218 | + $video['title'] = htmlspecialchars($video['title']); |
|
219 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | + ?> |
|
221 | 221 | <div class="browse-item yt-tile-default "> |
222 | 222 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
223 | 223 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -243,16 +243,16 @@ discard block |
||
243 | 243 | </div> |
244 | 244 | <div class="browse-item-row ytg-box"> |
245 | 245 | <?php |
246 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
247 | - $stmt->execute(); |
|
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | - $video['author'] = htmlspecialchars($video['author']); |
|
253 | - $video['title'] = htmlspecialchars($video['title']); |
|
254 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | - ?> |
|
246 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
247 | + $stmt->execute(); |
|
248 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | + $video['author'] = htmlspecialchars($video['author']); |
|
253 | + $video['title'] = htmlspecialchars($video['title']); |
|
254 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | + ?> |
|
256 | 256 | <div class="browse-item yt-tile-default "> |
257 | 257 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
258 | 258 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -278,16 +278,16 @@ discard block |
||
278 | 278 | </div> |
279 | 279 | <div class="browse-item-row ytg-box"> |
280 | 280 | <?php |
281 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
282 | - $stmt->execute(); |
|
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | - $video['author'] = htmlspecialchars($video['author']); |
|
288 | - $video['title'] = htmlspecialchars($video['title']); |
|
289 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | - ?> |
|
281 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Entertainment' ORDER BY rand() LIMIT 4"); |
|
282 | + $stmt->execute(); |
|
283 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | + $video['author'] = htmlspecialchars($video['author']); |
|
288 | + $video['title'] = htmlspecialchars($video['title']); |
|
289 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | + ?> |
|
291 | 291 | <div class="browse-item yt-tile-default "> |
292 | 292 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
293 | 293 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -11,13 +11,13 @@ discard block |
||
11 | 11 | <?php |
12 | 12 | $search = $_SESSION['siteusername']; |
13 | 13 | |
14 | - if($_GET['filter'] == "time") { |
|
14 | + if ($_GET['filter'] == "time") { |
|
15 | 15 | $stmt = $__db->prepare("SELECT * FROM playlists WHERE author = :username ORDER BY id DESC"); |
16 | 16 | $stmt->bindParam(":username", $_SESSION['siteusername']); |
17 | 17 | $stmt->execute(); |
18 | 18 | $result = $stmt->get_result(); |
19 | 19 | $results = $result->num_rows; |
20 | - } else if($_GET['filter'] == "title") { |
|
20 | + } else if ($_GET['filter'] == "title") { |
|
21 | 21 | $stmt = $__db->prepare("SELECT * FROM playlists WHERE author = :username ORDER BY title DESC"); |
22 | 22 | $stmt->bindParam(":username", $_SESSION['siteusername']); |
23 | 23 | $stmt->execute(); |
@@ -30,18 +30,18 @@ discard block |
||
30 | 30 | <th style="width: 80%;"> |
31 | 31 | <small class="video-filter-options"> |
32 | 32 | Sort by: |
33 | - <a id="selector-title" onclick="changeFilter_Title();" <?php if($_GET['filter'] == "title") { ?>class="selected"<?php } ?>>Title</a> | |
|
34 | - <a id="selector-time" onclick="changeFilter_Time();" <?php if($_GET['filter'] == "time") { ?>class="selected"<?php } ?>>Time</a> |
|
33 | + <a id="selector-title" onclick="changeFilter_Title();" <?php if ($_GET['filter'] == "title") { ?>class="selected"<?php } ?>>Title</a> | |
|
34 | + <a id="selector-time" onclick="changeFilter_Time();" <?php if ($_GET['filter'] == "time") { ?>class="selected"<?php } ?>>Time</a> |
|
35 | 35 | </small> |
36 | 36 | </th> |
37 | 37 | <th style="margin: 5px; width: 20%;"></th> |
38 | 38 | </tr> |
39 | 39 | |
40 | 40 | <?php |
41 | - while($playlist = $result->fetch_assoc()) { |
|
41 | + while ($playlist = $result->fetch_assoc()) { |
|
42 | 42 | $playlist['videos'] = json_decode($playlist['videos']); |
43 | - if($__video_h->video_exists(@$playlist['videos'][0])) { |
|
44 | - if(count($playlist['videos']) != 0) { |
|
43 | + if ($__video_h->video_exists(@$playlist['videos'][0])) { |
|
44 | + if (count($playlist['videos']) != 0) { |
|
45 | 45 | $video = $__video_h->fetch_video_rid($playlist['videos'][0]); |
46 | 46 | $video['video_responses'] = $__video_h->get_video_responses($video['rid']); |
47 | 47 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | <?php |
141 | 141 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
142 | 142 | $stmt->execute(); |
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
143 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | 144 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
145 | 145 | $video['duration'] = $__time_h->timestamp($video['duration']); |
146 | 146 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | <?php |
176 | 176 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
177 | 177 | $stmt->execute(); |
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
178 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | 179 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
180 | 180 | $video['duration'] = $__time_h->timestamp($video['duration']); |
181 | 181 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | <?php |
211 | 211 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
212 | 212 | $stmt->execute(); |
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
213 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | 214 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
215 | 215 | $video['duration'] = $__time_h->timestamp($video['duration']); |
216 | 216 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | <?php |
246 | 246 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
247 | 247 | $stmt->execute(); |
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
248 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | 249 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
250 | 250 | $video['duration'] = $__time_h->timestamp($video['duration']); |
251 | 251 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -280,7 +280,7 @@ discard block |
||
280 | 280 | <?php |
281 | 281 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
282 | 282 | $stmt->execute(); |
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
283 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | 284 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
285 | 285 | $video['duration'] = $__time_h->timestamp($video['duration']); |
286 | 286 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -138,16 +138,16 @@ discard block |
||
138 | 138 | </div> |
139 | 139 | <div class="browse-item-row ytg-box"> |
140 | 140 | <?php |
141 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
142 | - $stmt->execute(); |
|
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | - $video['author'] = htmlspecialchars($video['author']); |
|
148 | - $video['title'] = htmlspecialchars($video['title']); |
|
149 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | - ?> |
|
141 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
142 | + $stmt->execute(); |
|
143 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | + $video['author'] = htmlspecialchars($video['author']); |
|
148 | + $video['title'] = htmlspecialchars($video['title']); |
|
149 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | + ?> |
|
151 | 151 | <div class="browse-item yt-tile-default "> |
152 | 152 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
153 | 153 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -173,16 +173,16 @@ discard block |
||
173 | 173 | </div> |
174 | 174 | <div class="browse-item-row ytg-box"> |
175 | 175 | <?php |
176 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
177 | - $stmt->execute(); |
|
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | - $video['author'] = htmlspecialchars($video['author']); |
|
183 | - $video['title'] = htmlspecialchars($video['title']); |
|
184 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | - ?> |
|
176 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
177 | + $stmt->execute(); |
|
178 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | + $video['author'] = htmlspecialchars($video['author']); |
|
183 | + $video['title'] = htmlspecialchars($video['title']); |
|
184 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | + ?> |
|
186 | 186 | <div class="browse-item yt-tile-default "> |
187 | 187 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
188 | 188 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -208,16 +208,16 @@ discard block |
||
208 | 208 | </div> |
209 | 209 | <div class="browse-item-row ytg-box"> |
210 | 210 | <?php |
211 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
212 | - $stmt->execute(); |
|
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | - $video['author'] = htmlspecialchars($video['author']); |
|
218 | - $video['title'] = htmlspecialchars($video['title']); |
|
219 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | - ?> |
|
211 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
212 | + $stmt->execute(); |
|
213 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | + $video['author'] = htmlspecialchars($video['author']); |
|
218 | + $video['title'] = htmlspecialchars($video['title']); |
|
219 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | + ?> |
|
221 | 221 | <div class="browse-item yt-tile-default "> |
222 | 222 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
223 | 223 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -243,16 +243,16 @@ discard block |
||
243 | 243 | </div> |
244 | 244 | <div class="browse-item-row ytg-box"> |
245 | 245 | <?php |
246 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
247 | - $stmt->execute(); |
|
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | - $video['author'] = htmlspecialchars($video['author']); |
|
253 | - $video['title'] = htmlspecialchars($video['title']); |
|
254 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | - ?> |
|
246 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
247 | + $stmt->execute(); |
|
248 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | + $video['author'] = htmlspecialchars($video['author']); |
|
253 | + $video['title'] = htmlspecialchars($video['title']); |
|
254 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | + ?> |
|
256 | 256 | <div class="browse-item yt-tile-default "> |
257 | 257 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
258 | 258 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -278,16 +278,16 @@ discard block |
||
278 | 278 | </div> |
279 | 279 | <div class="browse-item-row ytg-box"> |
280 | 280 | <?php |
281 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
282 | - $stmt->execute(); |
|
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | - $video['author'] = htmlspecialchars($video['author']); |
|
288 | - $video['title'] = htmlspecialchars($video['title']); |
|
289 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | - ?> |
|
281 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4"); |
|
282 | + $stmt->execute(); |
|
283 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | + $video['author'] = htmlspecialchars($video['author']); |
|
288 | + $video['title'] = htmlspecialchars($video['title']); |
|
289 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | + ?> |
|
291 | 291 | <div class="browse-item yt-tile-default "> |
292 | 292 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
293 | 293 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -1,7 +1,7 @@ |
||
1 | 1 | <?php |
2 | 2 | require($_SERVER['DOCUMENT_ROOT'] . "/s/classes/config.inc.php"); |
3 | 3 | |
4 | -if(isset($_SESSION['siteusername'])) { |
|
4 | +if (isset($_SESSION['siteusername'])) { |
|
5 | 5 | $_SESSION = []; |
6 | 6 | session_destroy(); |
7 | 7 | } |
@@ -59,28 +59,28 @@ |
||
59 | 59 | require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . "/" . $requestedPage[2] . ".php"); |
60 | 60 | die(); |
61 | 61 | break; |
62 | - case 'd': |
|
63 | - if ($requestedPage[2] == "") { |
|
64 | - $requestedPage[2] = "index"; |
|
65 | - } |
|
66 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . "/" . $requestedPage[2] . ".php"); |
|
67 | - die(); |
|
68 | - break; |
|
62 | + case 'd': |
|
63 | + if ($requestedPage[2] == "") { |
|
64 | + $requestedPage[2] = "index"; |
|
65 | + } |
|
66 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . "/" . $requestedPage[2] . ".php"); |
|
67 | + die(); |
|
68 | + break; |
|
69 | 69 | case 'user': |
70 | 70 | $_GET['n'] = $requestedPage[2]; |
71 | 71 | require_once($_SERVER['DOCUMENT_ROOT'] . "/channel.php"); |
72 | 72 | die(); |
73 | 73 | break; |
74 | 74 | default: |
75 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/config.inc.php"); |
|
76 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/db_helper.php"); |
|
77 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/time_manip.php"); |
|
78 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/user_helper.php"); |
|
79 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/video_helper.php"); |
|
80 | - $__video_h = new video_helper($__db); |
|
81 | - $__user_h = new user_helper($__db); |
|
82 | - $__db_h = new db_helper(); |
|
83 | - $__time_h = new time_helper(); |
|
75 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/config.inc.php"); |
|
76 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/db_helper.php"); |
|
77 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/time_manip.php"); |
|
78 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/user_helper.php"); |
|
79 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/s/classes/video_helper.php"); |
|
80 | + $__video_h = new video_helper($__db); |
|
81 | + $__user_h = new user_helper($__db); |
|
82 | + $__db_h = new db_helper(); |
|
83 | + $__time_h = new time_helper(); |
|
84 | 84 | |
85 | 85 | if(empty($requestedPage[1])) |
86 | 86 | require_once($_SERVER['DOCUMENT_ROOT'] . "/homepage.php"); |
@@ -41,10 +41,11 @@ discard block |
||
41 | 41 | |
42 | 42 | $file_info = new finfo(FILEINFO_MIME_TYPE); |
43 | 43 | $mime_type = $file_info->buffer($file); |
44 | - if($mime_type == "text/plain") |
|
45 | - header('Content-Type: text/css'); |
|
46 | - else |
|
47 | - header('Content-Type: ' . $mime_type); |
|
44 | + if($mime_type == "text/plain") { |
|
45 | + header('Content-Type: text/css'); |
|
46 | + } else { |
|
47 | + header('Content-Type: ' . $mime_type); |
|
48 | + } |
|
48 | 49 | echo $file; |
49 | 50 | break; |
50 | 51 | case 'inbox': |
@@ -82,10 +83,11 @@ discard block |
||
82 | 83 | $__db_h = new db_helper(); |
83 | 84 | $__time_h = new time_helper(); |
84 | 85 | |
85 | - if(empty($requestedPage[1])) |
|
86 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/homepage.php"); |
|
87 | - else |
|
88 | - require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . ".php"); |
|
86 | + if(empty($requestedPage[1])) { |
|
87 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/homepage.php"); |
|
88 | + } else { |
|
89 | + require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . ".php"); |
|
90 | + } |
|
89 | 91 | die(); |
90 | 92 | break; |
91 | 93 | } |
92 | 94 | \ No newline at end of file |
@@ -3,7 +3,7 @@ discard block |
||
3 | 3 | |
4 | 4 | switch ($requestedPage[1]) { |
5 | 5 | case 'player': |
6 | - if($requestedPage[1] == "2009player" && $requestedPage[2] == "assets") { |
|
6 | + if ($requestedPage[1] == "2009player" && $requestedPage[2] == "assets") { |
|
7 | 7 | $a = implode("/", $requestedPage); |
8 | 8 | $i = implode(".", $requestedPage); |
9 | 9 | $file = file_get_contents($_SERVER['DOCUMENT_ROOT'] . $a); |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | $a = implode("/", $requestedPage); |
32 | 32 | $i = implode(".", $requestedPage); |
33 | 33 | // shitty fix plz dont use in production and stop using the shitty router bitch |
34 | - ini_set ('memory_limit', 400000000); |
|
34 | + ini_set('memory_limit', 400000000); |
|
35 | 35 | |
36 | 36 | // normal |
37 | 37 | $file = file_get_contents($_SERVER['DOCUMENT_ROOT'] . $a); |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | |
45 | 45 | $file_info = new finfo(FILEINFO_MIME_TYPE); |
46 | 46 | $mime_type = $file_info->buffer($file); |
47 | - if($mime_type == "text/plain") |
|
47 | + if ($mime_type == "text/plain") |
|
48 | 48 | header('Content-Type: text/css'); |
49 | 49 | else |
50 | 50 | header('Content-Type: ' . $mime_type); |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | $__db_h = new db_helper(); |
86 | 86 | $__time_h = new time_helper(); |
87 | 87 | |
88 | - if(empty($requestedPage[1])) |
|
88 | + if (empty($requestedPage[1])) |
|
89 | 89 | require_once($_SERVER['DOCUMENT_ROOT'] . "/homepage.php"); |
90 | 90 | else |
91 | 91 | require_once($_SERVER['DOCUMENT_ROOT'] . "/" . $requestedPage[1] . ".php"); |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | <?php |
141 | 141 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
142 | 142 | $stmt->execute(); |
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
143 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | 144 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
145 | 145 | $video['duration'] = $__time_h->timestamp($video['duration']); |
146 | 146 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | <?php |
176 | 176 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
177 | 177 | $stmt->execute(); |
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
178 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | 179 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
180 | 180 | $video['duration'] = $__time_h->timestamp($video['duration']); |
181 | 181 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | <?php |
211 | 211 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
212 | 212 | $stmt->execute(); |
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
213 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | 214 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
215 | 215 | $video['duration'] = $__time_h->timestamp($video['duration']); |
216 | 216 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | <?php |
246 | 246 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
247 | 247 | $stmt->execute(); |
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
248 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | 249 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
250 | 250 | $video['duration'] = $__time_h->timestamp($video['duration']); |
251 | 251 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -280,7 +280,7 @@ discard block |
||
280 | 280 | <?php |
281 | 281 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
282 | 282 | $stmt->execute(); |
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
283 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | 284 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
285 | 285 | $video['duration'] = $__time_h->timestamp($video['duration']); |
286 | 286 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -138,16 +138,16 @@ discard block |
||
138 | 138 | </div> |
139 | 139 | <div class="browse-item-row ytg-box"> |
140 | 140 | <?php |
141 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
142 | - $stmt->execute(); |
|
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | - $video['author'] = htmlspecialchars($video['author']); |
|
148 | - $video['title'] = htmlspecialchars($video['title']); |
|
149 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | - ?> |
|
141 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
142 | + $stmt->execute(); |
|
143 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | + $video['author'] = htmlspecialchars($video['author']); |
|
148 | + $video['title'] = htmlspecialchars($video['title']); |
|
149 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | + ?> |
|
151 | 151 | <div class="browse-item yt-tile-default "> |
152 | 152 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
153 | 153 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -173,16 +173,16 @@ discard block |
||
173 | 173 | </div> |
174 | 174 | <div class="browse-item-row ytg-box"> |
175 | 175 | <?php |
176 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
177 | - $stmt->execute(); |
|
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | - $video['author'] = htmlspecialchars($video['author']); |
|
183 | - $video['title'] = htmlspecialchars($video['title']); |
|
184 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | - ?> |
|
176 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
177 | + $stmt->execute(); |
|
178 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | + $video['author'] = htmlspecialchars($video['author']); |
|
183 | + $video['title'] = htmlspecialchars($video['title']); |
|
184 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | + ?> |
|
186 | 186 | <div class="browse-item yt-tile-default "> |
187 | 187 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
188 | 188 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -208,16 +208,16 @@ discard block |
||
208 | 208 | </div> |
209 | 209 | <div class="browse-item-row ytg-box"> |
210 | 210 | <?php |
211 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
212 | - $stmt->execute(); |
|
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | - $video['author'] = htmlspecialchars($video['author']); |
|
218 | - $video['title'] = htmlspecialchars($video['title']); |
|
219 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | - ?> |
|
211 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
212 | + $stmt->execute(); |
|
213 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | + $video['author'] = htmlspecialchars($video['author']); |
|
218 | + $video['title'] = htmlspecialchars($video['title']); |
|
219 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | + ?> |
|
221 | 221 | <div class="browse-item yt-tile-default "> |
222 | 222 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
223 | 223 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -243,16 +243,16 @@ discard block |
||
243 | 243 | </div> |
244 | 244 | <div class="browse-item-row ytg-box"> |
245 | 245 | <?php |
246 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
247 | - $stmt->execute(); |
|
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | - $video['author'] = htmlspecialchars($video['author']); |
|
253 | - $video['title'] = htmlspecialchars($video['title']); |
|
254 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | - ?> |
|
246 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
247 | + $stmt->execute(); |
|
248 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | + $video['author'] = htmlspecialchars($video['author']); |
|
253 | + $video['title'] = htmlspecialchars($video['title']); |
|
254 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | + ?> |
|
256 | 256 | <div class="browse-item yt-tile-default "> |
257 | 257 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
258 | 258 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -278,16 +278,16 @@ discard block |
||
278 | 278 | </div> |
279 | 279 | <div class="browse-item-row ytg-box"> |
280 | 280 | <?php |
281 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
282 | - $stmt->execute(); |
|
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | - $video['author'] = htmlspecialchars($video['author']); |
|
288 | - $video['title'] = htmlspecialchars($video['title']); |
|
289 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | - ?> |
|
281 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4"); |
|
282 | + $stmt->execute(); |
|
283 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | + $video['author'] = htmlspecialchars($video['author']); |
|
288 | + $video['title'] = htmlspecialchars($video['title']); |
|
289 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | + ?> |
|
291 | 291 | <div class="browse-item yt-tile-default "> |
292 | 292 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
293 | 293 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | <?php |
141 | 141 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
142 | 142 | $stmt->execute(); |
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
143 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | 144 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
145 | 145 | $video['duration'] = $__time_h->timestamp($video['duration']); |
146 | 146 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | <?php |
176 | 176 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
177 | 177 | $stmt->execute(); |
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
178 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | 179 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
180 | 180 | $video['duration'] = $__time_h->timestamp($video['duration']); |
181 | 181 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | <?php |
211 | 211 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
212 | 212 | $stmt->execute(); |
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
213 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | 214 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
215 | 215 | $video['duration'] = $__time_h->timestamp($video['duration']); |
216 | 216 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | <?php |
246 | 246 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
247 | 247 | $stmt->execute(); |
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
248 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | 249 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
250 | 250 | $video['duration'] = $__time_h->timestamp($video['duration']); |
251 | 251 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -280,7 +280,7 @@ discard block |
||
280 | 280 | <?php |
281 | 281 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
282 | 282 | $stmt->execute(); |
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
283 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | 284 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
285 | 285 | $video['duration'] = $__time_h->timestamp($video['duration']); |
286 | 286 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -138,16 +138,16 @@ discard block |
||
138 | 138 | </div> |
139 | 139 | <div class="browse-item-row ytg-box"> |
140 | 140 | <?php |
141 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
142 | - $stmt->execute(); |
|
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | - $video['author'] = htmlspecialchars($video['author']); |
|
148 | - $video['title'] = htmlspecialchars($video['title']); |
|
149 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | - ?> |
|
141 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
142 | + $stmt->execute(); |
|
143 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | + $video['author'] = htmlspecialchars($video['author']); |
|
148 | + $video['title'] = htmlspecialchars($video['title']); |
|
149 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | + ?> |
|
151 | 151 | <div class="browse-item yt-tile-default "> |
152 | 152 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
153 | 153 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -173,16 +173,16 @@ discard block |
||
173 | 173 | </div> |
174 | 174 | <div class="browse-item-row ytg-box"> |
175 | 175 | <?php |
176 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
177 | - $stmt->execute(); |
|
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | - $video['author'] = htmlspecialchars($video['author']); |
|
183 | - $video['title'] = htmlspecialchars($video['title']); |
|
184 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | - ?> |
|
176 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
177 | + $stmt->execute(); |
|
178 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | + $video['author'] = htmlspecialchars($video['author']); |
|
183 | + $video['title'] = htmlspecialchars($video['title']); |
|
184 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | + ?> |
|
186 | 186 | <div class="browse-item yt-tile-default "> |
187 | 187 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
188 | 188 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -208,16 +208,16 @@ discard block |
||
208 | 208 | </div> |
209 | 209 | <div class="browse-item-row ytg-box"> |
210 | 210 | <?php |
211 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
212 | - $stmt->execute(); |
|
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | - $video['author'] = htmlspecialchars($video['author']); |
|
218 | - $video['title'] = htmlspecialchars($video['title']); |
|
219 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | - ?> |
|
211 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
212 | + $stmt->execute(); |
|
213 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | + $video['author'] = htmlspecialchars($video['author']); |
|
218 | + $video['title'] = htmlspecialchars($video['title']); |
|
219 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | + ?> |
|
221 | 221 | <div class="browse-item yt-tile-default "> |
222 | 222 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
223 | 223 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -243,16 +243,16 @@ discard block |
||
243 | 243 | </div> |
244 | 244 | <div class="browse-item-row ytg-box"> |
245 | 245 | <?php |
246 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
247 | - $stmt->execute(); |
|
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | - $video['author'] = htmlspecialchars($video['author']); |
|
253 | - $video['title'] = htmlspecialchars($video['title']); |
|
254 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | - ?> |
|
246 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
247 | + $stmt->execute(); |
|
248 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | + $video['author'] = htmlspecialchars($video['author']); |
|
253 | + $video['title'] = htmlspecialchars($video['title']); |
|
254 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | + ?> |
|
256 | 256 | <div class="browse-item yt-tile-default "> |
257 | 257 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
258 | 258 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -278,16 +278,16 @@ discard block |
||
278 | 278 | </div> |
279 | 279 | <div class="browse-item-row ytg-box"> |
280 | 280 | <?php |
281 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
282 | - $stmt->execute(); |
|
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | - $video['author'] = htmlspecialchars($video['author']); |
|
288 | - $video['title'] = htmlspecialchars($video['title']); |
|
289 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | - ?> |
|
281 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Howto & Style' ORDER BY rand() LIMIT 4"); |
|
282 | + $stmt->execute(); |
|
283 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | + $video['author'] = htmlspecialchars($video['author']); |
|
288 | + $video['title'] = htmlspecialchars($video['title']); |
|
289 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | + ?> |
|
291 | 291 | <div class="browse-item yt-tile-default "> |
292 | 292 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
293 | 293 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | <?php |
141 | 141 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
142 | 142 | $stmt->execute(); |
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
143 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | 144 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
145 | 145 | $video['duration'] = $__time_h->timestamp($video['duration']); |
146 | 146 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | <?php |
176 | 176 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
177 | 177 | $stmt->execute(); |
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
178 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | 179 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
180 | 180 | $video['duration'] = $__time_h->timestamp($video['duration']); |
181 | 181 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | <?php |
211 | 211 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
212 | 212 | $stmt->execute(); |
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
213 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | 214 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
215 | 215 | $video['duration'] = $__time_h->timestamp($video['duration']); |
216 | 216 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | <?php |
246 | 246 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
247 | 247 | $stmt->execute(); |
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
248 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | 249 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
250 | 250 | $video['duration'] = $__time_h->timestamp($video['duration']); |
251 | 251 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -280,7 +280,7 @@ discard block |
||
280 | 280 | <?php |
281 | 281 | $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
282 | 282 | $stmt->execute(); |
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
283 | + while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | 284 | $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
285 | 285 | $video['duration'] = $__time_h->timestamp($video['duration']); |
286 | 286 | $video['views'] = $__video_h->fetch_video_views($video['rid']); |
@@ -138,16 +138,16 @@ discard block |
||
138 | 138 | </div> |
139 | 139 | <div class="browse-item-row ytg-box"> |
140 | 140 | <?php |
141 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
142 | - $stmt->execute(); |
|
143 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | - $video['author'] = htmlspecialchars($video['author']); |
|
148 | - $video['title'] = htmlspecialchars($video['title']); |
|
149 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | - ?> |
|
141 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
142 | + $stmt->execute(); |
|
143 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
144 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
145 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
146 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
147 | + $video['author'] = htmlspecialchars($video['author']); |
|
148 | + $video['title'] = htmlspecialchars($video['title']); |
|
149 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
150 | + ?> |
|
151 | 151 | <div class="browse-item yt-tile-default "> |
152 | 152 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
153 | 153 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -173,16 +173,16 @@ discard block |
||
173 | 173 | </div> |
174 | 174 | <div class="browse-item-row ytg-box"> |
175 | 175 | <?php |
176 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
177 | - $stmt->execute(); |
|
178 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | - $video['author'] = htmlspecialchars($video['author']); |
|
183 | - $video['title'] = htmlspecialchars($video['title']); |
|
184 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | - ?> |
|
176 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
177 | + $stmt->execute(); |
|
178 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
179 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
180 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
181 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
182 | + $video['author'] = htmlspecialchars($video['author']); |
|
183 | + $video['title'] = htmlspecialchars($video['title']); |
|
184 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
185 | + ?> |
|
186 | 186 | <div class="browse-item yt-tile-default "> |
187 | 187 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
188 | 188 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -208,16 +208,16 @@ discard block |
||
208 | 208 | </div> |
209 | 209 | <div class="browse-item-row ytg-box"> |
210 | 210 | <?php |
211 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
212 | - $stmt->execute(); |
|
213 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | - $video['author'] = htmlspecialchars($video['author']); |
|
218 | - $video['title'] = htmlspecialchars($video['title']); |
|
219 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | - ?> |
|
211 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
212 | + $stmt->execute(); |
|
213 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
214 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
215 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
216 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
217 | + $video['author'] = htmlspecialchars($video['author']); |
|
218 | + $video['title'] = htmlspecialchars($video['title']); |
|
219 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
220 | + ?> |
|
221 | 221 | <div class="browse-item yt-tile-default "> |
222 | 222 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
223 | 223 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -243,16 +243,16 @@ discard block |
||
243 | 243 | </div> |
244 | 244 | <div class="browse-item-row ytg-box"> |
245 | 245 | <?php |
246 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
247 | - $stmt->execute(); |
|
248 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | - $video['author'] = htmlspecialchars($video['author']); |
|
253 | - $video['title'] = htmlspecialchars($video['title']); |
|
254 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | - ?> |
|
246 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
247 | + $stmt->execute(); |
|
248 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
249 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
250 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
251 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
252 | + $video['author'] = htmlspecialchars($video['author']); |
|
253 | + $video['title'] = htmlspecialchars($video['title']); |
|
254 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
255 | + ?> |
|
256 | 256 | <div class="browse-item yt-tile-default "> |
257 | 257 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
258 | 258 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |
@@ -278,16 +278,16 @@ discard block |
||
278 | 278 | </div> |
279 | 279 | <div class="browse-item-row ytg-box"> |
280 | 280 | <?php |
281 | - $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
282 | - $stmt->execute(); |
|
283 | - while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | - $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | - $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | - $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | - $video['author'] = htmlspecialchars($video['author']); |
|
288 | - $video['title'] = htmlspecialchars($video['title']); |
|
289 | - $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | - ?> |
|
281 | + $stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'People & Blogs' ORDER BY rand() LIMIT 4"); |
|
282 | + $stmt->execute(); |
|
283 | + while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { |
|
284 | + $video['age'] = $__time_h->time_elapsed_string($video['publish']); |
|
285 | + $video['duration'] = $__time_h->timestamp($video['duration']); |
|
286 | + $video['views'] = $__video_h->fetch_video_views($video['rid']); |
|
287 | + $video['author'] = htmlspecialchars($video['author']); |
|
288 | + $video['title'] = htmlspecialchars($video['title']); |
|
289 | + $video['description'] = $__video_h->shorten_description($video['description'], 50); |
|
290 | + ?> |
|
291 | 291 | <div class="browse-item yt-tile-default "> |
292 | 292 | <a href="/watch?v=<?php echo $video['rid']; ?>" class="ux-thumb-wrap yt-uix-sessionlink yt-uix-contextlink contains-addto " data-sessionlink="ei=CPjwu5ji3bICFS4RIQod9j-M-A%3D%3D&feature=b-mv"><span class="video-thumb ux-thumb yt-thumb-default-194 "><span class="yt-thumb-clip"><span class="yt-thumb-clip-inner"><img src="http://s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Thumbnail" onerror="this.onerror=null;this.src='/dynamic/thumbs/default.jpg';" data-thumb="/dynamic/thumbs/<?php echo $video['thumbnail']; ?>" width="194"><span class="vertical-align"></span></span></span></span><span class="video-time"><?php echo $video['duration']; ?></span> |
293 | 293 | <button onclick=";return false;" title="Watch Later" type="button" class="addto-button video-actions addto-watch-later-button-sign-in yt-uix-button yt-uix-button-default yt-uix-button-short yt-uix-tooltip" data-button-menu-id="shared-addto-watch-later-login" data-video-ids="rLHU-_OhT8g" role="button"><span class="yt-uix-button-content"> <img src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt="Watch Later"> |