Completed
Push — master ( 285880...d65ec1 )
by mains
02:43
created
index.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
 	$accessToken;
15 15
 	$newPositionStatus;
16 16
 	
17
-	if ($result->num_rows > 0)
17
+	if($result->num_rows > 0)
18 18
 	{
19 19
 		// output data of each row
20 20
 		while($row = $result->fetch_assoc())
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
 				<a href="index.php">
115 115
 					<h1>
116 116
 						JodelBlue
117
-						<?php if(!isset($_GET['postID']) && !isset($_GET['getPostDetails'])) echo '<i class="fa fa-refresh fa-1x"></i>';?>
117
+						<?php if(!isset($_GET['postID']) && !isset($_GET['getPostDetails'])) echo '<i class="fa fa-refresh fa-1x"></i>'; ?>
118 118
 					</h1>					
119 119
 				</a>
120 120
 				<div class="clear"></div>
@@ -131,11 +131,11 @@  discard block
 block discarded – undo
131 131
 							if(isset($_GET['postID']) && isset($_GET['getPostDetails'])) {
132 132
 								//Header Nav in Comment View
133 133
 								?>
134
-								<a id="comment-back" href="index.php#postId-<?php echo htmlspecialchars($_GET['postID']);?>">
134
+								<a id="comment-back" href="index.php#postId-<?php echo htmlspecialchars($_GET['postID']); ?>">
135 135
 									<i class="fa fa-angle-left fa-3x"></i>
136 136
 								</a>
137 137
 
138
-								<a id="comment-refresh" href="index.php?getPostDetails=<?php echo htmlspecialchars($_GET['getPostDetails']);?>&postID=<?php echo htmlspecialchars($_GET['postID']);?>">
138
+								<a id="comment-refresh" href="index.php?getPostDetails=<?php echo htmlspecialchars($_GET['getPostDetails']); ?>&postID=<?php echo htmlspecialchars($_GET['postID']); ?>">
139 139
 									<i class="fa fa-refresh fa-2x"></i>
140 140
 								</a>
141 141
 								<?php
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
 							}
183 183
 							
184 184
 
185
-							for($i = 0; $i<$loops; $i++) {
185
+							for($i = 0; $i < $loops; $i++) {
186 186
 							
187 187
 							if(isset($posts[$i])) {
188 188
 							$lastPostId = $posts[$i]['post_id'];
@@ -200,24 +200,24 @@  discard block
 block discarded – undo
200 200
 							$timediff_inHours = (string)$timediff->format('%h');
201 201
 							$timediff_inDays = (string)$timediff->format('%d');
202 202
 							$timediff_inMonth = (string)$timediff->format('%m');
203
-							if($timediff_inMonth!=0) {
203
+							if($timediff_inMonth != 0) {
204 204
 									$timediff = $timediff_inMonth . "m";
205 205
 							}
206 206
 							else
207 207
 							{
208
-								if($timediff_inDays!=0)
208
+								if($timediff_inDays != 0)
209 209
 								{
210 210
 									$timediff = $timediff_inDays . "d";
211 211
 								}
212 212
 								else
213 213
 								{
214
-									if($timediff_inHours!=0)
214
+									if($timediff_inHours != 0)
215 215
 									{
216 216
 										$timediff = $timediff_inHours . "h";
217 217
 									}
218 218
 									else
219 219
 									{
220
-										if($timediff_inMinutes!=0)
220
+										if($timediff_inMinutes != 0)
221 221
 										{
222 222
 											$timediff = $timediff_inMinutes . "m";
223 223
 										}
@@ -230,7 +230,7 @@  discard block
 block discarded – undo
230 230
 							}
231 231
 						?>
232 232
 						
233
-						<article id ="postId-<?php echo $posts[$i]["post_id"]; ?>" class="jodel" style="background-color: #<?php echo $posts[$i]["color"];?>;">
233
+						<article id ="postId-<?php echo $posts[$i]["post_id"]; ?>" class="jodel" style="background-color: #<?php echo $posts[$i]["color"]; ?>;">
234 234
 							<content>
235 235
 								<?php 
236 236
 								if(isset($posts[$i]["image_url"])) {
@@ -242,12 +242,12 @@  discard block
 block discarded – undo
242 242
 								?>
243 243
 							</content>
244 244
 							<aside>
245
-								<a href="index.php?vote=up&postID=<?php echo $posts[$i]["post_id"];?>">
245
+								<a href="index.php?vote=up&postID=<?php echo $posts[$i]["post_id"]; ?>">
246 246
 									<i class="fa fa-angle-up fa-3x"></i>
247 247
 								</a>	
248 248
 									<br />
249
-								<?php echo $posts[$i]["vote_count"];?><br />
250
-								<a href="index.php?vote=down&postID=<?php echo $posts[$i]["post_id"];?>">
249
+								<?php echo $posts[$i]["vote_count"]; ?><br />
250
+								<a href="index.php?vote=down&postID=<?php echo $posts[$i]["post_id"]; ?>">
251 251
 									<i class="fa fa-angle-down fa-3x"></i>
252 252
 								</a>
253 253
 							</aside>
@@ -258,13 +258,13 @@  discard block
 block discarded – undo
258 258
 										<td class="time">
259 259
 											<span data-tooltip="Time">
260 260
 												<i class="fa fa-clock-o"></i>
261
-												<?php echo $timediff;?>
261
+												<?php echo $timediff; ?>
262 262
 											</span> 
263 263
 										</td>
264 264
 										<td class="comments">
265 265
 											<?php if($showCommentIcon) {?>
266 266
 											<span data-tooltip="Comments">
267
-												<a href="index.php?getPostDetails=true&postID=<?php echo $posts[$i]["post_id"];?>">
267
+												<a href="index.php?getPostDetails=true&postID=<?php echo $posts[$i]["post_id"]; ?>">
268 268
 													<i class="fa fa-commenting-o"></i>
269 269
 													<?php if(array_key_exists("child_count", $posts[$i])) {
270 270
 																echo $posts[$i]["child_count"];
@@ -277,7 +277,7 @@  discard block
 block discarded – undo
277 277
 										<td class="distance">
278 278
 											<span data-tooltip="Distance">
279 279
 												<i class="fa fa-map-marker"></i>
280
-												<?php echo $posts[$i]["distance"];?> km
280
+												<?php echo $posts[$i]["distance"]; ?> km
281 281
 											</span>
282 282
 										</td>
283 283
 									</tr>
@@ -319,7 +319,7 @@  discard block
 block discarded – undo
319 319
 						<?php if(isset($_GET['postID']) && isset($_GET['getPostDetails'])) { ?>
320 320
 						<h2>Comment on Jodel</h2>
321 321
 						<form method="POST">				
322
-								<input type="hidden" name="ancestor" value="<?php echo htmlspecialchars($_GET['postID']);?>" />
322
+								<input type="hidden" name="ancestor" value="<?php echo htmlspecialchars($_GET['postID']); ?>" />
323 323
 								<textarea id="message" name="message" placeholder="Send a comment on a Jodel to all students within 10km" required></textarea> 
324 324
 							<br />
325 325
 							<input type="submit" value="SEND" /> 
@@ -344,13 +344,13 @@  discard block
 block discarded – undo
344 344
 				<div class="col-sm-12">
345 345
 					<div class="row">
346 346
 						<div class="col-sm-3">
347
-							<a href="index.php" <?php if(isset($timeView)) echo 'class="active"';?>><i class="fa fa-clock-o fa-3x"></i></a>
347
+							<a href="index.php" <?php if(isset($timeView)) echo 'class="active"'; ?>><i class="fa fa-clock-o fa-3x"></i></a>
348 348
 						</div>
349 349
 						<div class="col-sm-3">
350
-							<a href="index.php?commentView=true" <?php if(isset($commentView)) echo 'class="active"';?>><i class="fa fa-commenting-o fa-3x"></i></a>
350
+							<a href="index.php?commentView=true" <?php if(isset($commentView)) echo 'class="active"'; ?>><i class="fa fa-commenting-o fa-3x"></i></a>
351 351
 						</div>
352 352
 						<div class="col-sm-3">
353
-							<a href="index.php?upVoteView=true" <?php if(isset($upVoteView)) echo 'class="active"';?>><i class="fa fa-angle-up fa-3x"></i></a>
353
+							<a href="index.php?upVoteView=true" <?php if(isset($upVoteView)) echo 'class="active"'; ?>><i class="fa fa-angle-up fa-3x"></i></a>
354 354
 						</div>
355 355
 						<div class="col-sm-3">
356 356
 							<nav>
Please login to merge, or discard this patch.