Completed
Push — master ( 008aa0...00b67b )
by Christopher
13:47 queued 06:29
created
public/old/emailEvent.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
         $statusMessage = 'Sent successfully';
54 54
     } else {
55 55
         foreach ($sent as $errorMessage) {
56
-            $statusMessage .= '<p>'.$errorMessage.'</p>';
56
+            $statusMessage .= '<p>' . $errorMessage . '</p>';
57 57
         }
58 58
     }
59 59
 
Please login to merge, or discard this patch.
public/old/locations.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
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
 
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
             $sql = "UPDATE cr_locations SET name = '$name' WHERE id = '$editid'";
40 40
         }
41 41
         if (!mysqli_query(db(), $sql)) {
42
-            die('Error: '.mysqli_error(db()));
42
+            die('Error: ' . mysqli_error(db()));
43 43
         }
44 44
     } else {
45 45
         $newlocation = $_POST['newlocation'];
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 
51 51
         $sql = ("INSERT INTO cr_locations (name) VALUES ('$newlocation')");
52 52
         if (!mysqli_query(db(), $sql)) {
53
-            die('Error: '.mysqli_error(db()));
53
+            die('Error: ' . mysqli_error(db()));
54 54
         }
55 55
 
56 56
         // After we have inserted the data, we want to head back to the main users page
@@ -95,8 +95,8 @@  discard block
 block discarded – undo
95 95
 
96 96
     while ($row = mysqli_fetch_array($result, MYSQLI_ASSOC)) {
97 97
         $locationID = $row['id'];
98
-        echo "<span id='".$locationID."' class='edit'>".$row['name'].'</span> ';
99
-        echo " <a href='locations.php?locationremove=true&locationID=".$locationID."'><i class='fa fa-close'></i></a><br />";
98
+        echo "<span id='" . $locationID . "' class='edit'>" . $row['name'] . '</span> ';
99
+        echo " <a href='locations.php?locationremove=true&locationID=" . $locationID . "'><i class='fa fa-close'></i></a><br />";
100 100
     } ?>
101 101
  </div><!-- /.box-body -->
102 102
 </div><!-- /.box -->
Please login to merge, or discard this patch.
public/old/plugins/datatables/extensions/Scroller/examples/data/ssp.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -29,11 +29,11 @@
 block discarded – undo
29 29
 // parameter represents the DataTables column identifier. In this case simple
30 30
 // indexes
31 31
 $columns = [
32
-    ['db' => 'id',         'dt' => 0],
33
-    ['db' => 'firstname',  'dt' => 1],
34
-    ['db' => 'surname',    'dt' => 2],
35
-    ['db' => 'zip',        'dt' => 3],
36
-    ['db' => 'country',    'dt' => 4],
32
+    ['db' => 'id', 'dt' => 0],
33
+    ['db' => 'firstname', 'dt' => 1],
34
+    ['db' => 'surname', 'dt' => 2],
35
+    ['db' => 'zip', 'dt' => 3],
36
+    ['db' => 'country', 'dt' => 4],
37 37
 ];
38 38
 
39 39
 // SQL server connection information
Please login to merge, or discard this patch.
public/old/notification.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
 } else {
34 34
     $notificationId = getQueryStringForKey('id');
35 35
     $referer = getQueryStringForKey('click');
36
-    $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl().'/notification.php?id='.$notificationId.'&click='.$referer;
36
+    $_SESSION['redirectUrl'] = siteSettings()->getSiteUrl() . '/notification.php?id=' . $notificationId . '&click=' . $referer;
37 37
     header('Location: login.php');
38 38
     exit;
39 39
 }
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
     // redir if notification has URL
61 61
     $redir = notificationLink($notificationId);
62 62
     if (!empty($redir)) {
63
-        header('Location: '.$redir);
63
+        header('Location: ' . $redir);
64 64
     }
65 65
 
66 66
     // find notification
Please login to merge, or discard this patch.
api-classes/User.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -24,12 +24,12 @@
 block discarded – undo
24 24
     public function createInDb(Database $db)
25 25
     {
26 26
         if (empty($this->name) || empty($this->datetime) || empty($this->series) || empty($this->type) || empty($this->sub_type) || empty($this->location)) {
27
-            $message = 'Series name ('.$this->name.')';
28
-            $message .= ' or date ('.$this->datetime.')';
29
-            $message .= ' or series ('.$this->series.')';
30
-            $message .= ' or type ('.$this->type.')';
31
-            $message .= ' or sub_type ('.$this->sub_type.')';
32
-            $message .= ' or location ('.$this->location.')';
27
+            $message = 'Series name (' . $this->name . ')';
28
+            $message .= ' or date (' . $this->datetime . ')';
29
+            $message .= ' or series (' . $this->series . ')';
30
+            $message .= ' or type (' . $this->type . ')';
31
+            $message .= ' or sub_type (' . $this->sub_type . ')';
32
+            $message .= ' or location (' . $this->location . ')';
33 33
             $message .= ' cannot be empty.';
34 34
 
35 35
             throw new Exception($message);
Please login to merge, or discard this patch.
api-classes/Database.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -180,10 +180,10 @@  discard block
 block discarded – undo
180 180
             if ($first) {
181 181
                 $first = false;
182 182
                 $fields .= $item['field'];
183
-                $valuesPlaceholder .= ':'.$item['field'];
183
+                $valuesPlaceholder .= ':' . $item['field'];
184 184
             } else {
185
-                $fields .= ', '.$item['field'];
186
-                $valuesPlaceholder .= ', :'.$item['field'];
185
+                $fields .= ', ' . $item['field'];
186
+                $valuesPlaceholder .= ', :' . $item['field'];
187 187
             }
188 188
 
189 189
             if ($item['type'] == 's' || $item['type'] == 'string') {
@@ -201,9 +201,9 @@  discard block
 block discarded – undo
201 201
             }
202 202
         }
203 203
 
204
-        $statement = $this->db_connection->prepare('INSERT INTO '.$table.' ('.$fields.') VALUES ('.$valuesPlaceholder.')');
204
+        $statement = $this->db_connection->prepare('INSERT INTO ' . $table . ' (' . $fields . ') VALUES (' . $valuesPlaceholder . ')');
205 205
         foreach ($data as $item) {
206
-            $statement->bindParam(':'.$item['field'], $item['value']);
206
+            $statement->bindParam(':' . $item['field'], $item['value']);
207 207
         }
208 208
 
209 209
         if ($statement->execute()) {
@@ -248,7 +248,7 @@  discard block
 block discarded – undo
248 248
 
249 249
     private function addPrefix($table)
250 250
     {
251
-        $table = $this->db_prefix.$table;
251
+        $table = $this->db_prefix . $table;
252 252
 
253 253
         return $table;
254 254
     }
@@ -272,7 +272,7 @@  discard block
 block discarded – undo
272 272
     public function count($table, $column, $where = null)
273 273
     {
274 274
         $columns = [
275
-      'COUNT('.$column.') AS count',
275
+      'COUNT(' . $column . ') AS count',
276 276
      ];
277 277
         $statement = $this->selectStatement($table, $columns, $where);
278 278
 
Please login to merge, or discard this patch.
api-classes/Event.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
     {
109 109
         foreach ($rehersals as $rehersal) {
110 110
             if (!is_a($rehersal, 'Rehersal')) {
111
-                throw new Exception('Rehersal is not a Rehersal object: '.$rehersal, 1);
111
+                throw new Exception('Rehersal is not a Rehersal object: ' . $rehersal, 1);
112 112
             }
113 113
         }
114 114
         $this->rehersals = $rehersals;
@@ -117,12 +117,12 @@  discard block
 block discarded – undo
117 117
     public function createInDb(Database $db)
118 118
     {
119 119
         if (empty($this->name) || empty($this->datetime) || empty($this->series) || empty($this->type) || empty($this->subType) || empty($this->location)) {
120
-            $message = 'Series name ('.$this->name.')';
121
-            $message .= ' or date ('.$this->datetime.')';
122
-            $message .= ' or series ('.$this->series.')';
123
-            $message .= ' or type ('.$this->type.')';
124
-            $message .= ' or sub_type ('.$this->subType.')';
125
-            $message .= ' or location ('.$this->location.')';
120
+            $message = 'Series name (' . $this->name . ')';
121
+            $message .= ' or date (' . $this->datetime . ')';
122
+            $message .= ' or series (' . $this->series . ')';
123
+            $message .= ' or type (' . $this->type . ')';
124
+            $message .= ' or sub_type (' . $this->subType . ')';
125
+            $message .= ' or location (' . $this->location . ')';
126 126
             $message .= ' cannot be empty.';
127 127
 
128 128
             throw new Exception($message);
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
     ];
181 181
 
182 182
         $where = [
183
-      'id = '.$id,
183
+      'id = ' . $id,
184 184
     ];
185 185
 
186 186
         $result = $db->selectSingle('Event', $this->db_table, $columns, $where);
Please login to merge, or discard this patch.
api-classes/Person.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -24,12 +24,12 @@
 block discarded – undo
24 24
     public function createInDb(Database $db)
25 25
     {
26 26
         if (empty($this->name) || empty($this->datetime) || empty($this->series) || empty($this->type) || empty($this->sub_type) || empty($this->location)) {
27
-            $message = 'Series name ('.$this->name.')';
28
-            $message .= ' or date ('.$this->datetime.')';
29
-            $message .= ' or series ('.$this->series.')';
30
-            $message .= ' or type ('.$this->type.')';
31
-            $message .= ' or sub_type ('.$this->sub_type.')';
32
-            $message .= ' or location ('.$this->location.')';
27
+            $message = 'Series name (' . $this->name . ')';
28
+            $message .= ' or date (' . $this->datetime . ')';
29
+            $message .= ' or series (' . $this->series . ')';
30
+            $message .= ' or type (' . $this->type . ')';
31
+            $message .= ' or sub_type (' . $this->sub_type . ')';
32
+            $message .= ' or location (' . $this->location . ')';
33 33
             $message .= ' cannot be empty.';
34 34
 
35 35
             throw new Exception($message);
Please login to merge, or discard this patch.
public/old/events.php 1 patch
Spacing   +22 added lines, -22 removed lines patch added patch discarded remove patch
@@ -48,9 +48,9 @@  discard block
 block discarded – undo
48 48
 } else {
49 49
     $urlFilters = '';
50 50
     if (isset($_SESSION['lastEventsFilter'])) {
51
-        $urlFilters = '&filter='.$_SESSION['lastEventsFilter'];
51
+        $urlFilters = '&filter=' . $_SESSION['lastEventsFilter'];
52 52
     }
53
-    header('Location: events.php?view=all'.$urlFilters);
53
+    header('Location: events.php?view=all' . $urlFilters);
54 54
     exit;
55 55
 }
56 56
 
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         session_destroy();
71 71
         header('Location: login.php');
72 72
     } else {
73
-        header('Location: events.php?view='.$sessionUserID);
73
+        header('Location: events.php?view=' . $sessionUserID);
74 74
         exit;
75 75
     }
76 76
 }
@@ -108,11 +108,11 @@  discard block
 block discarded – undo
108 108
     if ($editskillID != '') {
109 109
         $sql = ("INSERT INTO cr_eventPeople (eventId, userRoleId) VALUES ('$editeventID', '$editskillID')");
110 110
         if (!mysqli_query(db(), $sql)) {
111
-            die('Error: '.mysqli_error(db()));
111
+            die('Error: ' . mysqli_error(db()));
112 112
         }
113 113
 
114 114
         // After we have inserted the data, we want to head back to the main page
115
-        header('Location: index.php#section'.$editeventID);
115
+        header('Location: index.php#section' . $editeventID);
116 116
         exit;
117 117
     }
118 118
 
@@ -125,12 +125,12 @@  discard block
 block discarded – undo
125 125
 
126 126
             $sql = ("INSERT INTO cr_eventPeople (eventId, userRoleId) VALUES ('$editeventID', '$editskillID')");
127 127
             if (!mysqli_query(db(), $sql)) {
128
-                die('Error: '.mysqli_error(db()));
128
+                die('Error: ' . mysqli_error(db()));
129 129
             }
130 130
         }
131 131
 
132 132
         // After we have inserted the data, we want to head back to the main page
133
-        header('Location: index.php#section'.$editeventID);
133
+        header('Location: index.php#section' . $editeventID);
134 134
         exit;
135 135
     }
136 136
 }
@@ -176,7 +176,7 @@  discard block
 block discarded – undo
176 176
                     $result = mysqli_query(db(), $mysqli_query) or die(mysqli_error(db()));
177 177
                     $row = mysqli_fetch_object($result);
178 178
 
179
-                    echo $row->name.'s';
179
+                    echo $row->name . 's';
180 180
                 } elseif ($_SESSION['onlyShowUserEvents'] == '1') {
181 181
                     echo 'My Events';
182 182
                 } else {
@@ -202,7 +202,7 @@  discard block
 block discarded – undo
202 202
 			
203 203
 			<?php if (!empty($pendingSwaps) && $pendingSwaps > 0):
204 204
                 if ($pendingSwaps > 1) {
205
-                    $swapsMessage = $pendingSwaps.' swaps are pending approval. Emails have been sent to the people covering to approve the swaps.';
205
+                    $swapsMessage = $pendingSwaps . ' swaps are pending approval. Emails have been sent to the people covering to approve the swaps.';
206 206
                 } else {
207 207
                     $swapsMessage = 'A swap is pending approval. An email has been sent to the person covering to approve the swap.';
208 208
                 } ?>
@@ -270,7 +270,7 @@  discard block
 block discarded – undo
270 270
 							WHERE e.type = '$filter'
271 271
 							AND e.date >= DATE(NOW())
272 272
 							AND e.removed = 0
273
-							ORDER BY ".$dateOrderBy;
273
+							ORDER BY " . $dateOrderBy;
274 274
     } else {
275 275
         $sql = "SELECT
276 276
 							DISTINCT e.id AS id,
@@ -298,7 +298,7 @@  discard block
 block discarded – undo
298 298
 							WHERE e.date >= DATE(NOW())
299 299
 							AND ur.userId = '$view'
300 300
 							AND e.removed = 0
301
-							ORDER BY ".$dateOrderBy;
301
+							ORDER BY " . $dateOrderBy;
302 302
     }
303 303
     $result = mysqli_query(db(), $sql) or die(mysqli_error(db()));
304 304
 
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
         $newMonth = strftime('%B %Y', strtotime($row->sundayDate));
317 317
         if ($month != $newMonth) {
318 318
             $month = $newMonth;
319
-            echo '<li class="time-label"><span class="bg-green">'.$month.'</span></li>';
319
+            echo '<li class="time-label"><span class="bg-green">' . $month . '</span></li>';
320 320
         }
321 321
 
322 322
         // Event details?>
@@ -330,9 +330,9 @@  discard block
 block discarded – undo
330 330
 						<h4><?php
331 331
                             echo date('jS: ', strtotime($row->sundayDate));
332 332
         if ($eventName != '') {
333
-            echo '<strong>'.$eventName.'</strong><br />'.$subType.' - <em>'.$type.'</em>';
333
+            echo '<strong>' . $eventName . '</strong><br />' . $subType . ' - <em>' . $type . '</em>';
334 334
         } else {
335
-            echo $subType.' - <em>'.$type.'</em>';
335
+            echo $subType . ' - <em>' . $type . '</em>';
336 336
         } ?>
337 337
 						</h4>
338 338
 					</a>
@@ -344,7 +344,7 @@  discard block
 block discarded – undo
344 344
 				<?php //<p><strong>Rehearsal:</strong> <?php
345 345
                 //echo ($row->rehearsalDateFormatted = "0000-00-00 00:00:00") ? "none" : strftime(siteSettings()->time_format_normal,strtotime($row->rehearsalDateFormatted));</p>?>
346 346
 					
347
-				<p><strong><?php echo $row->eventGroup ? $row->eventGroup.': ' : '' ?></strong><?php echo $row->sermonTitle ?> <?php echo $row->bibleVerse ? '('.$row->bibleVerse.')' : '' ?></p>
347
+				<p><strong><?php echo $row->eventGroup ? $row->eventGroup . ': ' : '' ?></strong><?php echo $row->sermonTitle ?> <?php echo $row->bibleVerse ? '(' . $row->bibleVerse . ')' : '' ?></p>
348 348
 				
349 349
 				<p><strong>Location:</strong> <?php echo $row->eventLocation; ?></p>
350 350
 				
@@ -416,16 +416,16 @@  discard block
 block discarded – undo
416 416
                                 } else {
417 417
                                     echo '</ul>';
418 418
                                 }
419
-                                echo '<p><strong>'.$groupName.'</strong></p>';
419
+                                echo '<p><strong>' . $groupName . '</strong></p>';
420 420
                                 echo '<ul>';
421 421
                             }
422 422
 
423 423
                             echo '<li>';
424
-                            echo (isset($viewPeople->swap)) ? "<s><a class='text-danger' href='swap.php?swap=".$viewPeople->swap."'>" : '';
424
+                            echo (isset($viewPeople->swap)) ? "<s><a class='text-danger' href='swap.php?swap=" . $viewPeople->swap . "'>" : '';
425 425
                             echo $viewPeople->name;
426 426
 
427 427
                             if ($viewPeople->rolename != '') {
428
-                                echo ' - <em>'.$viewPeople->rolename.'</em>';
428
+                                echo ' - <em>' . $viewPeople->rolename . '</em>';
429 429
                             } else {
430 430
                                 // If there is no skill, we don't need to mention this.
431 431
                             }
@@ -451,9 +451,9 @@  discard block
 block discarded – undo
451 451
 
452 452
 				<?php
453 453
                 if (isAdmin() || $userisBandAdmin || $userisEventEditor) {
454
-                    echo " <a class ='btn btn-primary' href='createEvent.php?action=edit&id=".$eventID."'><i class='fa fa-pencil'></i><span> &nbsp;Edit</span></a> "; /* Edit event */
455
-                    echo " <a class ='btn btn-primary' href='createEvent.php?action=copy&id=".$eventID."'><i class='fa fa-pencil'></i><span> &nbsp;Copy</span></a> "; /* Edit event */
456
-                    echo " <a class ='btn btn-primary' href='emailEvent.php?event=".$eventID."'><i class='fa fa-envelope-o'></i><span> &nbsp;Send email</span></a> "; /* Send email */
454
+                    echo " <a class ='btn btn-primary' href='createEvent.php?action=edit&id=" . $eventID . "'><i class='fa fa-pencil'></i><span> &nbsp;Edit</span></a> "; /* Edit event */
455
+                    echo " <a class ='btn btn-primary' href='createEvent.php?action=copy&id=" . $eventID . "'><i class='fa fa-pencil'></i><span> &nbsp;Copy</span></a> "; /* Edit event */
456
+                    echo " <a class ='btn btn-primary' href='emailEvent.php?event=" . $eventID . "'><i class='fa fa-envelope-o'></i><span> &nbsp;Send email</span></a> "; /* Send email */
457 457
                 }
458 458
         if (isAdmin()) {
459 459
             //echo "<a class='btn btn-primary' href='index.php?notifyEveryone=true&eventID=$eventID'><i class='fa fa-envelope-o'></i><span> &nbsp;Send email</span></a> "; /* Send email */
@@ -462,7 +462,7 @@  discard block
 block discarded – undo
462 462
 
463 463
             echo "<ul class='dropdown-menu'>";
464 464
 
465
-            echo "<li><button type='button' class='btn btn-danger btn-block' data-toggle='modal' data-target='#deleteModal".$eventID."'>Delete</button></li>"; /* Delete Event */
465
+            echo "<li><button type='button' class='btn btn-danger btn-block' data-toggle='modal' data-target='#deleteModal" . $eventID . "'>Delete</button></li>"; /* Delete Event */
466 466
 
467 467
             echo '</ul>';
468 468
         } ?>
Please login to merge, or discard this patch.