@@ -119,7 +119,7 @@ |
||
119 | 119 | |
120 | 120 | <div class="box box-primary"> |
121 | 121 | <div class="box-header"> |
122 | - <h2 class="box-title">Change password - <?php echo $firstname.' '.$lastname.'<br>'; ?></h2> |
|
122 | + <h2 class="box-title">Change password - <?php echo $firstname . ' ' . $lastname . '<br>'; ?></h2> |
|
123 | 123 | </div><!-- /.box-header --> |
124 | 124 | <div class="box-body"> |
125 | 125 |
@@ -49,7 +49,7 @@ discard block |
||
49 | 49 | } |
50 | 50 | |
51 | 51 | $token = createCalendarToken($sessionUserId, $format, $description); |
52 | - $url = siteSettings()->getSiteUrl()."/calendar.php?user=$sessionUserId&format=$format&token=$token"; |
|
52 | + $url = siteSettings()->getSiteUrl() . "/calendar.php?user=$sessionUserId&format=$format&token=$token"; |
|
53 | 53 | break; |
54 | 54 | } |
55 | 55 | } |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | <?php echo empty($calendars) ? '<p>none</p>' : '' ?> |
129 | 129 | <?php foreach ($calendars as $calendar): ?> |
130 | 130 | <?php echo $calendar->revoked ? '<s>' : '' ?> |
131 | - <p><?php echo $calendar->description.' ('.$calendar->format.')'; ?></p> |
|
131 | + <p><?php echo $calendar->description . ' (' . $calendar->format . ')'; ?></p> |
|
132 | 132 | <?php if (!$calendar->revoked): ?> |
133 | 133 | <form action="#" method="post"> |
134 | 134 | <input type="hidden" name="method" value="revoke" /> |
@@ -25,6 +25,6 @@ |
||
25 | 25 | $helper = $fb->getRedirectLoginHelper(); |
26 | 26 | |
27 | 27 | $permissions = ['email']; // Optional permissions |
28 | -$loginUrl = $helper->getLoginUrl(siteSettings()->getSiteUrl().'/fb-callback.php', $permissions); |
|
28 | +$loginUrl = $helper->getLoginUrl(siteSettings()->getSiteUrl() . '/fb-callback.php', $permissions); |
|
29 | 29 | |
30 | -header('Location: '.$loginUrl); |
|
30 | +header('Location: ' . $loginUrl); |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | exit; |
36 | 36 | } |
37 | 37 | if (!isAdmin()) { |
38 | - header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME'])); |
|
38 | + header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME'])); |
|
39 | 39 | exit; |
40 | 40 | } |
41 | 41 | |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | if ($editskillID != '') { |
72 | 72 | $sql = ("INSERT INTO cr_eventPeople (eventID, skillID) VALUES ('$editeventID', '$editskillID')"); |
73 | 73 | if (!mysqli_query(db(), $sql)) { |
74 | - die('Error: '.mysqli_error(db())); |
|
74 | + die('Error: ' . mysqli_error(db())); |
|
75 | 75 | } |
76 | 76 | |
77 | 77 | // After we have inserted the data, we want to head back to the main page |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | |
89 | 89 | $sql = ("INSERT INTO cr_eventPeople (eventID, skillID) VALUES ('$editeventID', '$editskillID')"); |
90 | 90 | if (!mysqli_query(db(), $sql)) { |
91 | - die('Error: '.mysqli_error(db())); |
|
91 | + die('Error: ' . mysqli_error(db())); |
|
92 | 92 | } |
93 | 93 | } |
94 | 94 |
@@ -47,7 +47,7 @@ |
||
47 | 47 | break; |
48 | 48 | case 'unlink': |
49 | 49 | removeSocialAuthFromUserWithId($id, $platform); |
50 | - createNotificationForUser($id, ucfirst($platform).' account unlinked', 'You have successfully unlinked your Facebook account. Login via Facebook is now disabled for your account. Feel free to relink your account at any time.', 'account', 'linkSocialAuth.php'); |
|
50 | + createNotificationForUser($id, ucfirst($platform) . ' account unlinked', 'You have successfully unlinked your Facebook account. Login via Facebook is now disabled for your account. Feel free to relink your account at any time.', 'account', 'linkSocialAuth.php'); |
|
51 | 51 | break; |
52 | 52 | |
53 | 53 | default: |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | |
10 | 10 | // ensure user is logged in |
11 | 11 | if (!(isset($_SESSION['is_logged_in']) || $_SESSION['db_is_logged_in'] == true)) { |
12 | - $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl().'/termCard.php'; |
|
12 | + $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl() . '/termCard.php'; |
|
13 | 13 | header('Location: login.php'); |
14 | 14 | } |
15 | 15 | |
@@ -42,12 +42,12 @@ discard block |
||
42 | 42 | |
43 | 43 | while ($ob = mysqli_fetch_object($result)) { |
44 | 44 | echo '<tr>'; |
45 | - echo '<td>'.date('j F', strtotime($ob->eventDate)).'</td>'; |
|
46 | - echo '<td>'.date('g:i a', strtotime($ob->eventDate)).'</td>'; |
|
47 | - echo '<td>'.$ob->eventName.'</td>'; |
|
48 | - echo '<td>'.$ob->eventSubType.'</td>'; |
|
49 | - echo '<td>'.$ob->sermonTitle; |
|
50 | - echo $ob->bibleVerse ? ' ('.$ob->bibleVerse.')</td>' : ''; |
|
45 | + echo '<td>' . date('j F', strtotime($ob->eventDate)) . '</td>'; |
|
46 | + echo '<td>' . date('g:i a', strtotime($ob->eventDate)) . '</td>'; |
|
47 | + echo '<td>' . $ob->eventName . '</td>'; |
|
48 | + echo '<td>' . $ob->eventSubType . '</td>'; |
|
49 | + echo '<td>' . $ob->sermonTitle; |
|
50 | + echo $ob->bibleVerse ? ' (' . $ob->bibleVerse . ')</td>' : ''; |
|
51 | 51 | echo '</tr>'; |
52 | 52 | } |
53 | 53 | echo '</table>'; |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | session_start(); |
9 | 9 | |
10 | 10 | if (!(isset($_SESSION['is_logged_in']) || $_SESSION['db_is_logged_in'] == true)) { |
11 | - $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl().'/addUser.php?'.$_SERVER['QUERY_STRING']; |
|
11 | + $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl() . '/addUser.php?' . $_SERVER['QUERY_STRING']; |
|
12 | 12 | header('Location: login.php'); |
13 | 13 | exit; |
14 | 14 | } |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | $userRole = UserRoleQuery::create()->filterByUser($user)->filterByRoleId($roleId)->findOne(); |
57 | 57 | $userRole->setReserve(false); |
58 | 58 | $userRole->save(); |
59 | - header('Location: addUser.php?action=edit&user='.$user->getId()); |
|
59 | + header('Location: addUser.php?action=edit&user=' . $user->getId()); |
|
60 | 60 | exit; |
61 | 61 | |
62 | 62 | break; |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | $userRole = UserRoleQuery::create()->filterByUser($user)->filterByRoleId($roleId)->findOne(); |
68 | 68 | $userRole->setReserve(true); |
69 | 69 | $userRole->save(); |
70 | - header('Location: addUser.php?action=edit&user='.$user->getId()); |
|
70 | + header('Location: addUser.php?action=edit&user=' . $user->getId()); |
|
71 | 71 | exit; |
72 | 72 | break; |
73 | 73 | |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | } |
177 | 177 | } |
178 | 178 | if (isAdmin()) { |
179 | - header('Location: users.php#section'.$userId); |
|
179 | + header('Location: users.php#section' . $userId); |
|
180 | 180 | exit; |
181 | 181 | } |
182 | 182 | } |
@@ -261,7 +261,7 @@ discard block |
||
261 | 261 | // ordered in this way to build the page with contact details before permissions |
262 | 262 | if (!isAdmin()) { |
263 | 263 | if ($userId == $sessionUserID) { |
264 | - echo $firstname.' '.$lastname; |
|
264 | + echo $firstname . ' ' . $lastname; |
|
265 | 265 | $isCompromised = false; |
266 | 266 | } else { |
267 | 267 | notifyAttack(__FILE__, 'Impersonating Attack', $sessionUserID); |
@@ -48,18 +48,18 @@ discard block |
||
48 | 48 | if ($postremove == 'true') { |
49 | 49 | removePost($postid); |
50 | 50 | if ($redirect == 'true') { |
51 | - header('Location: discussion.php?categoryid='.$parentid); |
|
51 | + header('Location: discussion.php?categoryid=' . $parentid); |
|
52 | 52 | } else { |
53 | - header('Location: discussiontopic.php?id='.$id.'&parentid='.$parentid); |
|
53 | + header('Location: discussiontopic.php?id=' . $id . '&parentid=' . $parentid); |
|
54 | 54 | } |
55 | 55 | } |
56 | 56 | |
57 | 57 | if ($subscribe == 'true') { |
58 | 58 | subscribeto($userID, 0, $id); |
59 | - header('Location: discussiontopic.php?id='.$id.'&parentid='.$parentid); |
|
59 | + header('Location: discussiontopic.php?id=' . $id . '&parentid=' . $parentid); |
|
60 | 60 | } elseif ($subscribe == 'false') { |
61 | 61 | unsubscribefrom($subscription); |
62 | - header('Location: discussiontopic.php?id='.$id.'&parentid='.$parentid); |
|
62 | + header('Location: discussiontopic.php?id=' . $id . '&parentid=' . $parentid); |
|
63 | 63 | } |
64 | 64 | |
65 | 65 | // If the form has been sent, we need to handle the data. |
@@ -74,18 +74,18 @@ discard block |
||
74 | 74 | // If we are starting a new discussion |
75 | 75 | $sql = ("INSERT INTO cr_discussion (CategoryParent, userID, topic, topicName, date) VALUES ('$parentid', '$userID', '$discussion', '$discussiontopic', NOW())"); |
76 | 76 | if (!mysqli_query(db(), $sql)) { |
77 | - die('Error: '.mysqli_error(db())); |
|
77 | + die('Error: ' . mysqli_error(db())); |
|
78 | 78 | } |
79 | 79 | $type = 'category'; |
80 | 80 | notifySubscribers($parentid, $type, $userID); |
81 | - header('Location: discussion.php?categoryid='.$parentid); |
|
81 | + header('Location: discussion.php?categoryid=' . $parentid); |
|
82 | 82 | exit; |
83 | 83 | } else { |
84 | 84 | // Otherwise we reply in thread |
85 | 85 | $sql = ("INSERT INTO cr_discussion (topicParent, CategoryParent, userID, topic, date) |
86 | 86 | VALUES ('$id', '$parentid', '$userID', '$discussion', NOW())"); |
87 | 87 | if (!mysqli_query(db(), $sql)) { |
88 | - die('Error: '.mysqli_error(db())); |
|
88 | + die('Error: ' . mysqli_error(db())); |
|
89 | 89 | } |
90 | 90 | if ($subscribestatus == 'false') { |
91 | 91 | subscribeto($userID, 0, $id); |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | <div class="elementBackground"> |
139 | 139 | <h2><a name="addcategory"><?php echo $row['name']; ?></a> - <span class="postdate"><em><?php echo $row['dateFormatted']; ?></em></span> |
140 | 140 | <?php if (isAdmin()) { |
141 | - echo "<a href='discussiontopic.php?redirect=true&postremove=true&postid=".$row['id'].'&parentid='.$parentid."'><img src='graphics/close.png' /></a><br />"; |
|
141 | + echo "<a href='discussiontopic.php?redirect=true&postremove=true&postid=" . $row['id'] . '&parentid=' . $parentid . "'><img src='graphics/close.png' /></a><br />"; |
|
142 | 142 | } ?> |
143 | 143 | </h2> |
144 | 144 | <p><?php echo stripslashes($topic); ?></p> |
@@ -158,7 +158,7 @@ discard block |
||
158 | 158 | <div class="elementBackground"> |
159 | 159 | <h2><a name="addcategory"><?php echo $row['name']; ?></a> - <span class="postdate"><em><?php echo $row['dateFormatted']; ?></em></span> |
160 | 160 | <?php if (isAdmin()) { |
161 | - echo "<a href='discussiontopic.php?postremove=true&postid=".$row['id'].'&parentid='.$parentid.'&id='.$id."'><img src='graphics/close.png' /></a>"; |
|
161 | + echo "<a href='discussiontopic.php?postremove=true&postid=" . $row['id'] . '&parentid=' . $parentid . '&id=' . $id . "'><img src='graphics/close.png' /></a>"; |
|
162 | 162 | } ?></h2> |
163 | 163 | <p><?php echo stripslashes($topic); ?></p> |
164 | 164 | </div> |
@@ -176,11 +176,11 @@ discard block |
||
176 | 176 | } |
177 | 177 | |
178 | 178 | if ($isSubscribed != '') { |
179 | - $subscribe = '<div class="item"><a href="discussiontopic.php?subscribe=false&subscription='.$isSubscribed.'&id='. |
|
180 | - $id.'&parentid='.$parentid.'">Unsubscribe from this post</a></div>'; |
|
179 | + $subscribe = '<div class="item"><a href="discussiontopic.php?subscribe=false&subscription=' . $isSubscribed . '&id=' . |
|
180 | + $id . '&parentid=' . $parentid . '">Unsubscribe from this post</a></div>'; |
|
181 | 181 | $subscribestatus = 'true'; |
182 | 182 | } else { |
183 | - $subscribe = '<div class="item"><a href="discussiontopic.php?subscribe=true&id='.$id.'&parentid='.$parentid.'"> |
|
183 | + $subscribe = '<div class="item"><a href="discussiontopic.php?subscribe=true&id=' . $id . '&parentid=' . $parentid . '"> |
|
184 | 184 | Subscribe to this post</a></div>'; |
185 | 185 | $subscribestatus = 'false'; |
186 | 186 | } |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | exit; |
15 | 15 | } |
16 | 16 | if (!isAdmin()) { |
17 | - header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME'])); |
|
17 | + header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME'])); |
|
18 | 18 | exit; |
19 | 19 | } |
20 | 20 | |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | $sql = ("INSERT INTO cr_instruments (name) VALUES ('$neweventtype')"); |
37 | 37 | |
38 | 38 | if (!mysqli_query(db(), $sql)) { |
39 | - die('Error: '.mysqli_error(db())); |
|
39 | + die('Error: ' . mysqli_error(db())); |
|
40 | 40 | } |
41 | 41 | } else { |
42 | 42 | // Otherwise we are dealing with edits, not new stuff |
@@ -68,10 +68,10 @@ discard block |
||
68 | 68 | $result = mysqli_query(db(), $sql) or die(mysqli_error(db())); |
69 | 69 | |
70 | 70 | while ($row = mysqli_fetch_array($result, MYSQLI_ASSOC)) { |
71 | - echo '<input type="hidden" name="formindex[]" value="'.$row['id'].'" />'; |
|
72 | - echo "<input name='description[]' value='".$row['name']."' />"; |
|
71 | + echo '<input type="hidden" name="formindex[]" value="' . $row['id'] . '" />'; |
|
72 | + echo "<input name='description[]' value='" . $row['name'] . "' />"; |
|
73 | 73 | |
74 | - echo "<a href='bandskills.php?bandskillremove=true&bandskillID=".$row['id']."'><img src='graphics/close.png' /></a><br />"; |
|
74 | + echo "<a href='bandskills.php?bandskillremove=true&bandskillID=" . $row['id'] . "'><img src='graphics/close.png' /></a><br />"; |
|
75 | 75 | } ?> |
76 | 76 | </fieldset> |
77 | 77 | <input type="submit" value="Update band skills" /> |