Test Failed
Push — main ( 1c70d7...b09f12 )
by chief
02:52
created
web/public/playlists.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -12,13 +12,13 @@  discard block
 block discarded – undo
12 12
 <?php $__user_u = new user_update($__db); ?>
13 13
 <?php $__db_h = new db_helper(); ?>
14 14
 <?php $__time_h = new time_helper(); ?>
15
-<?php if(!isset($_SESSION['siteusername'])) { header("Location: /sign_in"); } ?>
15
+<?php if (!isset($_SESSION['siteusername'])) { header("Location: /sign_in"); } ?>
16 16
 <?php
17
-    if($_SERVER['REQUEST_METHOD'] == 'POST') {
18
-        if(!isset($_SESSION['siteusername'])){ $error_legacy = "you are not logged in"; goto skipcomment; }
19
-        if(!$_POST['comment']){ $error_legacy = "your description cannot be blank"; goto skipcomment; }
20
-        if(strlen($_POST['comment']) > 1024){ $error_legacy = "your comment must be shorter than 1000 characters"; goto skipcomment; }
21
-        if($__user_h->if_cooldown($_SESSION['siteusername'])) { $error_legacy = "You are on a cooldown! Wait for a minute before posting another comment."; goto skipcomment; }
17
+    if ($_SERVER['REQUEST_METHOD'] == 'POST') {
18
+        if (!isset($_SESSION['siteusername'])) { $error_legacy = "you are not logged in"; goto skipcomment; }
19
+        if (!$_POST['comment']) { $error_legacy = "your description cannot be blank"; goto skipcomment; }
20
+        if (strlen($_POST['comment']) > 1024) { $error_legacy = "your comment must be shorter than 1000 characters"; goto skipcomment; }
21
+        if ($__user_h->if_cooldown($_SESSION['siteusername'])) { $error_legacy = "You are on a cooldown! Wait for a minute before posting another comment."; goto skipcomment; }
22 22
 
23 23
         $stmt = $__db->prepare("INSERT INTO playlists (title, description, rid, author) VALUES (:title, :desc, :rid, :username)");
24 24
         $stmt->bindParam(":title", $_POST['title']);
@@ -187,15 +187,15 @@  discard block
 block discarded – undo
187 187
                                     $stmt->execute();
188 188
 
189 189
                                     $number_of_result = $stmt->rowCount();
190
-                                    $number_of_page = ceil ($number_of_result / $results_per_page);  
190
+                                    $number_of_page = ceil($number_of_result/$results_per_page);  
191 191
 
192
-                                    if (!isset ($_GET['page']) ) {  
192
+                                    if (!isset ($_GET['page'])) {  
193 193
                                         $page = 1;  
194 194
                                     } else {  
195
-                                        $page = (int)$_GET['page'];  
195
+                                        $page = (int) $_GET['page'];  
196 196
                                     }  
197 197
 
198
-                                    $page_first_result = ($page - 1) * $results_per_page;  
198
+                                    $page_first_result = ($page - 1)*$results_per_page;  
199 199
                                 ?>
200 200
                                 <?php 
201 201
                                     $stmt6 = $__db->prepare("SELECT * FROM playlists WHERE author = :search ORDER BY id DESC LIMIT :pfirst, :pper");
@@ -240,10 +240,10 @@  discard block
 block discarded – undo
240 240
                                     </tr>
241 241
                                     
242 242
                                     <?php
243
-                                        while($playlist = $stmt->fetch(PDO::FETCH_ASSOC)) { 
243
+                                        while ($playlist = $stmt->fetch(PDO::FETCH_ASSOC)) { 
244 244
                                             $playlist['videos'] = json_decode($playlist['videos']);
245
-                                            if($__video_h->video_exists(@$playlist['videos'][0])) {
246
-                                                if(count($playlist['videos']) != 0) {
245
+                                            if ($__video_h->video_exists(@$playlist['videos'][0])) {
246
+                                                if (count($playlist['videos']) != 0) {
247 247
                                                     $video = $__video_h->fetch_video_rid($playlist['videos'][0]);
248 248
                                                     $video['video_responses'] = $__video_h->get_video_responses($video['rid']);
249 249
                                                     $video['age'] = $__time_h->time_elapsed_string($video['publish']);		
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
                                     </div>
295 295
                                 </center>
296 296
 
297
-                                <?php for($page = 1; $page<= $number_of_page; $page++) { ?>
297
+                                <?php for ($page = 1; $page <= $number_of_page; $page++) { ?>
298 298
                                     <button class="yt-uix-button yt-uix-button-default" onclick="ajax_fetch_videomanager(<?php echo $page; ?>)"><?php echo $page; ?></button>
299 299
                                 <?php } ?>   
300 300
 
@@ -340,7 +340,7 @@  discard block
 block discarded – undo
340 340
                                 </script>
341 341
 
342 342
                                 <?php 
343
-                                    if($stmt6->rowCount() == 0) { echo "
343
+                                    if ($stmt6->rowCount() == 0) { echo "
344 344
                                         <br>Welcome to your playlists! You can make collections of videos for you to share with others.<br>
345 345
                                     "; 
346 346
                                 } ?>
Please login to merge, or discard this patch.
web/public/activism.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 										<?php
141 141
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' 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
 block discarded – undo
175 175
 										<?php
176 176
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' 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
 block discarded – undo
210 210
 										<?php
211 211
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' 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
 block discarded – undo
245 245
 										<?php
246 246
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' 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
 block discarded – undo
280 280
 										<?php
281 281
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' 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']);
Please login to merge, or discard this patch.
web/public/channel.php 1 patch
Spacing   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -13,10 +13,10 @@  discard block
 block discarded – undo
13 13
 <?php $__db_h = new db_helper(); ?>
14 14
 <?php $__time_h = new time_helper(); ?>
15 15
 <?php
16
-	if(isset($_SESSION['siteusername']))
16
+	if (isset($_SESSION['siteusername']))
17 17
 	    $_user_hp = $__user_h->fetch_user_username($_SESSION['siteusername']);
18 18
 
19
-    if(!$__user_h->user_exists($_GET['n']))
19
+    if (!$__user_h->user_exists($_GET['n']))
20 20
         header("Location: /?userdoesntexist");
21 21
 
22 22
     $_user = $__user_h->fetch_user_username($_GET['n']);
@@ -68,28 +68,28 @@  discard block
 block discarded – undo
68 68
 
69 69
     $_user['genre'] = strtolower($_user['genre']);
70 70
 
71
-    if(!check_valid_colorhex($_user['primary_color']) && strlen($_user['primary_color']) != 6) { $_user['primary_color'] = ""; }
72
-    if(!check_valid_colorhex($_user['secondary_color']) && strlen($_user['secondary_color']) != 6) { $_user['secondary_color'] = ""; }
73
-    if(!check_valid_colorhex($_user['third_color']) && strlen($_user['third_color']) != 6) { $_user['third_color'] = ""; }
74
-    if(!check_valid_colorhex($_user['text_color']) && strlen($_user['text_color']) != 6) { $_user['text_color'] = ""; }
75
-    if(!check_valid_colorhex($_user['primary_color_text']) && strlen($_user['primary_color_text']) != 6) { $_user['primary_color_text'] = ""; }
76
-    if(!check_valid_colorhex($_user['2009_bgcolor']) && strlen($_user['2009_bgcolor']) != 6) { $_user['2009_bgcolor'] = ""; }
71
+    if (!check_valid_colorhex($_user['primary_color']) && strlen($_user['primary_color']) != 6) { $_user['primary_color'] = ""; }
72
+    if (!check_valid_colorhex($_user['secondary_color']) && strlen($_user['secondary_color']) != 6) { $_user['secondary_color'] = ""; }
73
+    if (!check_valid_colorhex($_user['third_color']) && strlen($_user['third_color']) != 6) { $_user['third_color'] = ""; }
74
+    if (!check_valid_colorhex($_user['text_color']) && strlen($_user['text_color']) != 6) { $_user['text_color'] = ""; }
75
+    if (!check_valid_colorhex($_user['primary_color_text']) && strlen($_user['primary_color_text']) != 6) { $_user['primary_color_text'] = ""; }
76
+    if (!check_valid_colorhex($_user['2009_bgcolor']) && strlen($_user['2009_bgcolor']) != 6) { $_user['2009_bgcolor'] = ""; }
77 77
 
78
-	if(isset($_SESSION['siteusername']))
78
+	if (isset($_SESSION['siteusername']))
79 79
     	$__user_i->check_view_channel($_user['username'], @$_SESSION['siteusername']);
80 80
 
81
-    if($_SERVER['REQUEST_METHOD'] == 'POST') {
81
+    if ($_SERVER['REQUEST_METHOD'] == 'POST') {
82 82
         $error = array();
83 83
 
84
-        if(!isset($_SESSION['siteusername'])){ $error['message'] = "you are not logged in"; $error['status'] = true; }
85
-        if(!$_POST['comment']){ $error['message'] = "your comment cannot be blank"; $error['status'] = true; }
86
-        if(strlen($_POST['comment']) > 1000){ $error['message'] = "your comment must be shorter than 1000 characters"; $error['status'] = true; }
84
+        if (!isset($_SESSION['siteusername'])) { $error['message'] = "you are not logged in"; $error['status'] = true; }
85
+        if (!$_POST['comment']) { $error['message'] = "your comment cannot be blank"; $error['status'] = true; }
86
+        if (strlen($_POST['comment']) > 1000) { $error['message'] = "your comment must be shorter than 1000 characters"; $error['status'] = true; }
87 87
         //if(!isset($_POST['g-recaptcha-response'])){ $error['message'] = "captcha validation failed"; $error['status'] = true; }
88 88
         //if(!$_user_insert_utils->validateCaptcha($config['recaptcha_secret'], $_POST['g-recaptcha-response'])) { $error['message'] = "captcha validation failed"; $error['status'] = true; }
89
-        if($__user_h->if_cooldown($_SESSION['siteusername'])) { $error['message'] = "You are on a cooldown! Wait for a minute before posting another comment."; $error['status'] = true; }
89
+        if ($__user_h->if_cooldown($_SESSION['siteusername'])) { $error['message'] = "You are on a cooldown! Wait for a minute before posting another comment."; $error['status'] = true; }
90 90
         //if(ifBlocked(@$_SESSION['siteusername'], $user['username'], $__db)) { $error = "This user has blocked you!"; $error['status'] = true; } 
91 91
 
92
-        if(!isset($error['message'])) {
92
+        if (!isset($error['message'])) {
93 93
 			$text = $_POST['comment'];
94 94
             $stmt = $__db->prepare("INSERT INTO profile_comments (toid, author, comment) VALUES (:id, :username, :comment)");
95 95
 			$stmt->bindParam(":id", $_user['username']);
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
 
100 100
             $_user_update_utils->update_comment_cooldown_time($_SESSION['siteusername']);
101 101
 
102
-            if(@$_SESSION['siteusername'] != $_user['username']) { 
102
+            if (@$_SESSION['siteusername'] != $_user['username']) { 
103 103
                 $_user_insert_utils->send_message($_user['username'], "New comment", 'I commented "' . $_POST['comment'] . '" on your profile!', $_SESSION['siteusername']);
104 104
             }
105 105
         }
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
 		<link rel="stylesheet" href="/yt/cssbin/www-extra.css">
126 126
 		<style>
127 127
 			#content-container {
128
-				background-color: <?php echo $_user['primary_color'];  ?>;
128
+				background-color: <?php echo $_user['primary_color']; ?>;
129 129
 				background-image: url(/dynamic/banners/<?php echo $_user['2009_bg']; ?>);
130 130
 				background-repeat: repeat;
131 131
 				background-position: center top;
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
 			<div id="content-container">
143 143
 				<!-- begin content -->
144 144
 				<div id="content">
145
-					<?php if(isset($_SESSION['siteusername']) && $_user['username'] == $_SESSION['siteusername']) { ?>
145
+					<?php if (isset($_SESSION['siteusername']) && $_user['username'] == $_SESSION['siteusername']) { ?>
146 146
 						<div class="channel_customization"><?php echo require($_SERVER['DOCUMENT_ROOT'] . "/s/mod/channel_customization.php"); ?></div>
147 147
 					<?php } ?> 
148 148
 
@@ -197,7 +197,7 @@  discard block
 block discarded – undo
197 197
 												<h1><?php echo htmlspecialchars($_user['username']); ?></h1>
198 198
 											</div>
199 199
 											<div class="upper-left-section enable-fancy-subscribe-button">
200
-												<?php if($_user['username'] != @$_SESSION['siteusername']) { ?>
200
+												<?php if ($_user['username'] != @$_SESSION['siteusername']) { ?>
201 201
 													<div class="yt-subscription-button-hovercard yt-uix-hovercard">
202 202
 														<button href="https://accounts.google.com/ServiceLogin?uilel=3&amp;service=youtube&amp;passive=true&amp;continue=http%3A%2F%2Fwww.youtube.com%2Fsignin%3Faction_handle_signin%3Dtrue%26feature%3Dsubscribe%26nomobiletemp%3D1%26hl%3Den_US%26next%3D%252Fuser%252F<?php echo htmlspecialchars($_user['username']); ?>%253Ffeature%253Dg-logo-xit&amp;hl=en_US&amp;ltmpl=sso" onclick=";window.location.href=this.getAttribute('href');return false;" title="" type="button" class="yt-subscription-button subscription-button-with-recommended-channels   yt-uix-button yt-uix-button-subscription yt-uix-tooltip" data-enable-hovercard="true" data-subscription-value="UCIwFjwMjI0y7PDBVEO9-bkQ" data-force-position="" data-position="" data-subscription-feature="channels3" data-subscription-type="channel" role="button"><span class="yt-uix-button-icon-wrapper"><img class="yt-uix-button-icon yt-uix-button-icon-subscribe" src="//s.ytimg.com/yt/img/pixel-vfl3z5WfW.gif" alt=""></span><span class="yt-uix-button-content">  <span class="subscribe-label">Subscribe</span>
203 203
 														<span class="subscribed-label">Subscribed</span>
@@ -273,12 +273,12 @@  discard block
 block discarded – undo
273 273
 									</div>
274 274
 								</div>
275 275
 							</div>
276
-                            <?php if($_user['featured'] != "None") { $video = $__video_h->fetch_video_rid($_user['featured']); } else { $_user['featured'] = false; } ?>
276
+                            <?php if ($_user['featured'] != "None") { $video = $__video_h->fetch_video_rid($_user['featured']); } else { $_user['featured'] = false; } ?>
277 277
 							<div id="branded-page-body">
278 278
 								<div class="channel-tab-content channel-layout-two-column selected blogger-template">
279 279
 									<div class="tab-content-body">
280 280
 										<div class="primary-pane">
281
-                                            <?php if($_user['featured'] != false && $__video_h->video_exists($_user['featured'])) { ?>
281
+                                            <?php if ($_user['featured'] != false && $__video_h->video_exists($_user['featured'])) { ?>
282 282
 											<div class="channels-featured-video channel-module yt-uix-c3-module-container has-visible-edge">
283 283
 												<div class="module-view featured-video-view-module">
284 284
 													<div class="channels-video-player " data-swf-config="{&quot;assets&quot;: {&quot;html&quot;: &quot;\/html5_player_template&quot;, &quot;css&quot;: &quot;http:\/\/s.ytimg.com\/yt\/cssbin\/www-player-vfllhw7HB.css&quot;, &quot;js&quot;: &quot;http:\/\/s.ytimg.com\/yt\/jsbin\/html5player-vflzTrRqK.js&quot;}, &quot;url&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/watch_as3-vflbPspVE.swf&quot;, &quot;min_version&quot;: &quot;8.0.0&quot;, &quot;args&quot;: {&quot;ttsurl&quot;: &quot;http:\/\/www.youtube.com\/api\/timedtext?sparams=asr_langs%2Ccaps%2Cv%2Cexpire\u0026asr_langs=en%2Cko%2Cja%2Ces\u0026v=/watch?v=<?php echo $video['rid']; ?>\u0026caps=asr\u0026expire=1339746882\u0026key=yttt1\u0026signature=A1B858FF427B45672676C7403417ED1F4091A806.C347A6021C0F843E46F2056AEBA38FC93A0A47B8\u0026hl=en_US&quot;, &quot;el&quot;: &quot;profilepage&quot;, &quot;fexp&quot;: &quot;904001,907342,904824,910206,908620,907217,907335,921602,919306,922600,919316,920704,912804,913542,919324,912706&quot;, &quot;url_encoded_fmt_stream_map&quot;: &quot;url=http%3A%2F%2Fo-o.preferred.nuq04s10.v1.lscache4.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dcp%252Cid%252Cip%252Cipbits%252Citag%252Cratebypass%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26ms%3Dau%26itag%3D44%26ip%3D207.0.0.0%26signature%3D9B9B5ECF02F2F66BDCCB0ACED26D3406F9F83241.1B2CC833461E3D2C4D081B7DFBC65B0948C61FB9%26sver%3D3%26mt%3D1339721111%26ratebypass%3Dyes%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=large\u0026fallback_host=tc.v1.cache4.c.youtube.com\u0026type=video%2Fwebm%3B+codecs%3D%22vp8.0%2C+vorbis%22\u0026itag=44,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v14.lscache1.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dalgorithm%252Cburst%252Ccp%252Cfactor%252Cid%252Cip%252Cipbits%252Citag%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26mt%3D1339721111%26ms%3Dau%26algorithm%3Dthrottle-factor%26itag%3D35%26ip%3D207.0.0.0%26burst%3D40%26sver%3D3%26signature%3DB702D7CA72653169BDC2C945B5A35F4A23A3FEBF.ACC660CDAB11901FF8D3DA8D384D61F0AB0F0125%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26factor%3D1.25%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=large\u0026fallback_host=tc.v14.cache1.c.youtube.com\u0026type=video%2Fx-flv\u0026itag=35,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v24.lscache3.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dcp%252Cid%252Cip%252Cipbits%252Citag%252Cratebypass%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26ms%3Dau%26itag%3D43%26ip%3D207.0.0.0%26signature%3D9FABDD8C013AA137B87DF2D154D1B90E6827A2A3.880FECDEC066236D85FCF223CF472B62B8F9B3A4%26sver%3D3%26mt%3D1339721111%26ratebypass%3Dyes%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=medium\u0026fallback_host=tc.v24.cache3.c.youtube.com\u0026type=video%2Fwebm%3B+codecs%3D%22vp8.0%2C+vorbis%22\u0026itag=43,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v3.lscache7.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dalgorithm%252Cburst%252Ccp%252Cfactor%252Cid%252Cip%252Cipbits%252Citag%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26mt%3D1339721111%26ms%3Dau%26algorithm%3Dthrottle-factor%26itag%3D34%26ip%3D207.0.0.0%26burst%3D40%26sver%3D3%26signature%3D1BA326B784DAA9F62FD789CBB5C2FABFCD5D351C.C4618E3AB2AB08C61C6A982A36F405DA886B5D5A%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26factor%3D1.25%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=medium\u0026fallback_host=tc.v3.cache7.c.youtube.com\u0026type=video%2Fx-flv\u0026itag=34,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v14.lscache1.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dcp%252Cid%252Cip%252Cipbits%252Citag%252Cratebypass%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26ms%3Dau%26itag%3D18%26ip%3D207.0.0.0%26signature%3D8806EA8FAE16557A2F9732068442133EA0A0760F.D91694A47E6B0BF627965CDA46010F36105A28FE%26sver%3D3%26mt%3D1339721111%26ratebypass%3Dyes%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=medium\u0026fallback_host=tc.v14.cache1.c.youtube.com\u0026type=video%2Fmp4%3B+codecs%3D%22avc1.42001E%2C+mp4a.40.2%22\u0026itag=18,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v4.lscache1.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dalgorithm%252Cburst%252Ccp%252Cfactor%252Cid%252Cip%252Cipbits%252Citag%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26mt%3D1339721111%26ms%3Dau%26algorithm%3Dthrottle-factor%26itag%3D5%26ip%3D207.0.0.0%26burst%3D40%26sver%3D3%26signature%3D011CB6739AB60ED79D032DE2F62EB016D8A8E462.C2C0ABE42F26DBA18F2BC6E0D074EB99A95C0DF0%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26factor%3D1.25%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=small\u0026fallback_host=tc.v4.cache1.c.youtube.com\u0026type=video%2Fx-flv\u0026itag=5,url=http%3A%2F%2Fo-o.preferred.nuq04s10.v12.lscache3.c.youtube.com%2Fvideoplayback%3Fupn%3D_7WL7XeDtjs%26sparams%3Dalgorithm%252Cburst%252Ccp%252Cfactor%252Cid%252Cip%252Cipbits%252Citag%252Csource%252Cupn%252Cexpire%26fexp%3D904001%252C907342%252C904824%252C910206%252C908620%252C907217%252C907335%252C921602%252C919306%252C922600%252C919316%252C920704%252C912804%252C913542%252C919324%252C912706%26mt%3D1339721111%26ms%3Dau%26algorithm%3Dthrottle-factor%26itag%3D36%26ip%3D207.0.0.0%26burst%3D40%26sver%3D3%26signature%3D988FDD37CBA8DB74C1148EE17921D8549434297C.A2C1796F2BA0427C9FE370BFB6B3B09BA1D81B07%26source%3Dyoutube%26expire%3D1339743583%26key%3Dyt1%26ipbits%3D8%26factor%3D1.25%26cp%3DU0hSTldPUV9NTUNOMl9PSVVGOmdTcVlPRFNNTEdM%26id%3D56ffd0bfee85d71f\u0026quality=small\u0026fallback_host=tc.v12.cache3.c.youtube.com\u0026type=video%2F3gpp\u0026itag=36&quot;, &quot;allow_embed&quot;: 1, &quot;vq&quot;: &quot;auto&quot;, &quot;account_playback_token&quot;: &quot;&quot;, &quot;allow_ratings&quot;: 1, &quot;keywords&quot;: &quot;Rehearsal,Dance,justin,bieber,believe,as,long,you,love,me,rodney,jerkins,pattie,mallette,jeremy,dad,mom,scooter,braun,island,def,jam,usher,rbmg,making,of,the,album,webisode,june,19th,19,new,amazing,song,big,sean,hit,record,<?php echo htmlspecialchars($_user['username']); ?>,always,still,studio,singing,kuk,harrell,producer,sing,boy,guy,man,smash,single,nick,demoura,dancers,sweat,beliebers,hard,work,tour,band&quot;, &quot;cc3_module&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/subtitles3_module-vflu_Qeod.swf&quot;, &quot;track_embed&quot;: 0, &quot;is_purchased&quot;: false, &quot;ps&quot;: &quot;default&quot;, &quot;fmt_list&quot;: &quot;44\/854x480\/99\/0\/0,35\/854x480\/9\/0\/115,43\/640x360\/99\/0\/0,34\/640x360\/9\/0\/115,18\/640x360\/9\/0\/115,5\/320x240\/7\/0\/0,36\/320x240\/99\/0\/0&quot;, &quot;author&quot;: &quot;<?php echo htmlspecialchars($_user['username']); ?>&quot;, &quot;muted&quot;: &quot;0&quot;, &quot;cc_module&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/subtitle_module-vflq8KnSi.swf&quot;, &quot;length_seconds&quot;: 82, &quot;feature&quot;: &quot;g-logo-xit&quot;, &quot;enablejsapi&quot;: 1, &quot;rel&quot;: 0, &quot;plid&quot;: &quot;AATCeEL9eg3Ls9t-&quot;, &quot;cc_font&quot;: &quot;Arial Unicode MS, arial, verdana, _sans&quot;, &quot;ftoken&quot;: &quot;&quot;, &quot;sdetail&quot;: &quot;f:g-logo-xit,p:\/&quot;, &quot;status&quot;: &quot;ok&quot;, &quot;cc_asr&quot;: 1, &quot;watermark&quot;: &quot;,http:\/\/s.ytimg.com\/yt\/img\/watermark\/youtube_watermark-vflHX6b6E.png,http:\/\/s.ytimg.com\/yt\/img\/watermark\/youtube_hd_watermark-vflAzLcD6.png&quot;, &quot;sourceid&quot;: &quot;y&quot;, &quot;timestamp&quot;: 1339721682, &quot;has_cc&quot;: true, &quot;view_count&quot;: 2600, &quot;quality_cap&quot;: &quot;highres&quot;, &quot;hl&quot;: &quot;en_US&quot;, &quot;tmi&quot;: &quot;1&quot;, &quot;no_get_video_log&quot;: &quot;1&quot;, &quot;eurl&quot;: &quot;http:\/\/www.youtube.com\/user\/<?php echo htmlspecialchars($_user['username']); ?>&quot;, &quot;iurl&quot;: &quot;http:\/\/i3.ytimg.com\/vi\//watch?v=<?php echo $video['rid']; ?>\/hqdefault.jpg&quot;, &quot;endscreen_module&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/endscreen-vflJBKwqC.swf&quot;, &quot;referrer&quot;: &quot;http:\/\/www.youtube.com\/&quot;, &quot;avg_rating&quot;: 4.97805486284, &quot;video_id&quot;: &quot;/watch?v=<?php echo $video['rid']; ?>&quot;, &quot;sendtmp&quot;: &quot;1&quot;, &quot;sk&quot;: &quot;bwv_lGOGF4u1g0p7puy7ERICN8NZ5cVFC&quot;, &quot;is_video_preview&quot;: false, &quot;token&quot;: &quot;vjVQa1PpcFMSYb-unvOiIgSL8pW9tObJUMfrEc1mxfE=&quot;, &quot;thumbnail_url&quot;: &quot;http:\/\/i3.ytimg.com\/vi\//watch?v=<?php echo $video['rid']; ?>\/default.jpg&quot;, &quot;iurlsd&quot;: &quot;http:\/\/i3.ytimg.com\/vi\//watch?v=<?php echo $video['rid']; ?>\/sddefault.jpg&quot;, &quot;autoplay&quot;: &quot;1&quot;}, &quot;url_v9as2&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/cps-vflhvG6F4.swf&quot;, &quot;params&quot;: {&quot;allowscriptaccess&quot;: &quot;always&quot;, &quot;allowfullscreen&quot;: &quot;true&quot;, &quot;bgcolor&quot;: &quot;#000000&quot;}, &quot;attrs&quot;: {&quot;width&quot;: &quot;640&quot;, &quot;id&quot;: &quot;movie_player&quot;, &quot;height&quot;: &quot;390&quot;}, &quot;url_v8&quot;: &quot;http:\/\/s.ytimg.com\/yt\/swfbin\/cps-vflhvG6F4.swf&quot;, &quot;html5&quot;: false}" data-video-id="/watch?v=<?php echo $video['rid']; ?>">
@@ -324,7 +324,7 @@  discard block
 block discarded – undo
324 324
                                                             $stmt = $__db->prepare("SELECT * FROM videos WHERE author = :username ORDER BY id DESC LIMIT 20");
325 325
                                                             $stmt->bindParam(":username", $_user['username']);
326 326
                                                             $stmt->execute();
327
-                                                            while($video = $stmt->fetch(PDO::FETCH_ASSOC)) { 
327
+                                                            while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) { 
328 328
                                                         ?>
329 329
 														<li class="blogger-video">
330 330
 															<div class="video yt-tile-visible">
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
 														</div>
407 407
 														<hr class="yt-horizontal-rule ">
408 408
 													</div>
409
-													<?php if(!empty($_user['website'])) { ?>
409
+													<?php if (!empty($_user['website'])) { ?>
410 410
 														<div class="user-profile-item">
411 411
 															<div class="yt-c3-profile-custom-url field-container ">
412 412
 																<a href="<?php echo addhttp(htmlspecialchars($_user['website'])); ?>" rel="me nofollow" target="_blank" title="<?php echo htmlspecialchars($_user['website']); ?>" class="yt-uix-redirect-link">
@@ -455,7 +455,7 @@  discard block
 block discarded – undo
455 455
 															<h5>Country</h5>
456 456
 															<span class="value"><?php echo htmlspecialchars($_user['country']); ?></span>
457 457
 														</div>
458
-														<?php if($_user['genre'] != "none") { ?>
458
+														<?php if ($_user['genre'] != "none") { ?>
459 459
 															<div class="user-profile-item ">
460 460
 																<h5>Channel Genre</h5>
461 461
 																<span class="value"><?php echo htmlspecialchars($_user['genre']); ?></span>
Please login to merge, or discard this patch.
web/public/videos.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 										<?php
141 141
 											$stmt = $__db->prepare("SELECT * FROM videos 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']);
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
 										<?php
186 186
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Comedy' ORDER BY rand() LIMIT 4");
187 187
 											$stmt->execute();
188
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
188
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
189 189
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
190 190
 												$video['duration'] = $__time_h->timestamp($video['duration']);
191 191
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -230,7 +230,7 @@  discard block
 block discarded – undo
230 230
 										<?php
231 231
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Film & Animation' ORDER BY rand() LIMIT 4");
232 232
 											$stmt->execute();
233
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
233
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
234 234
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
235 235
 												$video['duration'] = $__time_h->timestamp($video['duration']);
236 236
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -279,7 +279,7 @@  discard block
 block discarded – undo
279 279
 										<?php
280 280
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Gaming' ORDER BY rand() LIMIT 4");
281 281
 											$stmt->execute();
282
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
282
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
283 283
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
284 284
 												$video['duration'] = $__time_h->timestamp($video['duration']);
285 285
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -328,7 +328,7 @@  discard block
 block discarded – undo
328 328
 										<?php
329 329
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Nonprofits & Activism' ORDER BY rand() LIMIT 4");
330 330
 											$stmt->execute();
331
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
331
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
332 332
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
333 333
 												$video['duration'] = $__time_h->timestamp($video['duration']);
334 334
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -377,7 +377,7 @@  discard block
 block discarded – undo
377 377
 										<?php
378 378
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Pets & Animals' ORDER BY rand() LIMIT 4");
379 379
 											$stmt->execute();
380
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
380
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
381 381
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
382 382
 												$video['duration'] = $__time_h->timestamp($video['duration']);
383 383
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -426,7 +426,7 @@  discard block
 block discarded – undo
426 426
 										<?php
427 427
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Science & Technology' ORDER BY rand() LIMIT 4");
428 428
 											$stmt->execute();
429
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
429
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
430 430
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
431 431
 												$video['duration'] = $__time_h->timestamp($video['duration']);
432 432
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
@@ -475,7 +475,7 @@  discard block
 block discarded – undo
475 475
 										<?php
476 476
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Travel & Events' ORDER BY rand() LIMIT 4");
477 477
 											$stmt->execute();
478
-											while($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
478
+											while ($video = $stmt->fetch(PDO::FETCH_ASSOC)) {	
479 479
 												$video['age'] = $__time_h->time_elapsed_string($video['publish']);		
480 480
 												$video['duration'] = $__time_h->timestamp($video['duration']);
481 481
 												$video['views'] = $__video_h->fetch_video_views($video['rid']);
Please login to merge, or discard this patch.
web/public/autos.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
 										<?php
141 141
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Autos & Vehicles' 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
 block discarded – undo
175 175
 										<?php
176 176
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Autos & Vehicles' 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
 block discarded – undo
210 210
 										<?php
211 211
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Autos & Vehicles' 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
 block discarded – undo
245 245
 										<?php
246 246
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Autos & Vehicles' 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
 block discarded – undo
280 280
 										<?php
281 281
 											$stmt = $__db->prepare("SELECT * FROM videos WHERE category = 'Autos & Vehicles' 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']);
Please login to merge, or discard this patch.
web/public/favorite_videos.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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 Video Manager! You can manage your uploaded videos here.<br>
311 311
                                         <a href=\"upload_video\">
312 312
                                             <button type=\"button\" class=\" yt-uix-button yt-uix-button-default\" role=\"button\">
Please login to merge, or discard this patch.
web/public/entertainment.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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']);
Please login to merge, or discard this patch.
web/public/playlists_ajax.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -11,13 +11,13 @@  discard block
 block discarded – undo
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
 block discarded – undo
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']);		
Please login to merge, or discard this patch.
web/public/travel.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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
 block discarded – undo
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']);
Please login to merge, or discard this patch.