@@ -14,7 +14,7 @@ |
||
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 |
@@ -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 | |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | $sql = "UPDATE cr_eventGroups SET name = '$name', description = '$description' WHERE id = '$editid'"; |
41 | 41 | } |
42 | 42 | if (!mysqli_query(db(), $sql)) { |
43 | - die('Error: '.mysqli_error(db())); |
|
43 | + die('Error: ' . mysqli_error(db())); |
|
44 | 44 | } |
45 | 45 | } else { |
46 | 46 | $name = $_POST['seriesName']; |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | } else { |
55 | 55 | $sql = ("INSERT INTO cr_eventGroups (name, description) VALUES ('$name', '$description')"); |
56 | 56 | if (!mysqli_query(db(), $sql)) { |
57 | - die('Error: '.mysqli_error(db())); |
|
57 | + die('Error: ' . mysqli_error(db())); |
|
58 | 58 | } |
59 | 59 | |
60 | 60 | // After we have inserted the data, we want to head back to the main users page |
@@ -97,9 +97,9 @@ discard block |
||
97 | 97 | |
98 | 98 | while ($row = mysqli_fetch_array($result, MYSQLI_ASSOC)) { |
99 | 99 | $seriesId = $row['id']; |
100 | - echo "<span id='".$seriesId."' class='edit'><strong>".$row['name'].'</strong></span>'; |
|
101 | - echo " <a href='series.php?method=remove&series=".$seriesId."'><i class='fa fa-close'></i></a><br />"; |
|
102 | - echo "<p id='".$seriesId."' class='edit'>".$row['description'].'</p>'; |
|
100 | + echo "<span id='" . $seriesId . "' class='edit'><strong>" . $row['name'] . '</strong></span>'; |
|
101 | + echo " <a href='series.php?method=remove&series=" . $seriesId . "'><i class='fa fa-close'></i></a><br />"; |
|
102 | + echo "<p id='" . $seriesId . "' class='edit'>" . $row['description'] . '</p>'; |
|
103 | 103 | echo '<hr />'; |
104 | 104 | } ?> |
105 | 105 | </div><!-- /.box-body --> |
@@ -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 | |
@@ -31,14 +31,14 @@ discard block |
||
31 | 31 | case 'approve': |
32 | 32 | $userId = approvePendingUser($id); |
33 | 33 | mailNewUser($userId); |
34 | - header('Location: addUser.php?action=edit&user='.$userId); |
|
34 | + header('Location: addUser.php?action=edit&user=' . $userId); |
|
35 | 35 | break; |
36 | 36 | case 'merge': |
37 | 37 | $existingUserId = $_POST['existingUser']; |
38 | 38 | $existingUserId = filter_var($existingUserId, FILTER_SANITIZE_NUMBER_INT); |
39 | 39 | mergePendingUserWithUserId($id, $existingUserId); |
40 | 40 | mailNewUser($existingUserId); |
41 | - header('Location: addUser.php?action=edit&user='.$existingUserId); |
|
41 | + header('Location: addUser.php?action=edit&user=' . $existingUserId); |
|
42 | 42 | break; |
43 | 43 | case 'decline': |
44 | 44 | declinePendingUser($id); |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | <div class="box box-primary"> |
91 | 91 | <div class="box-header"> |
92 | 92 | <h2 class="box-title"> |
93 | - <?php echo $user->approved ? 'Approved' : ($user->declined ? 'Declined' : 'Pending') ?>: <?php echo $user->firstName.' '.$user->lastName ?> |
|
93 | + <?php echo $user->approved ? 'Approved' : ($user->declined ? 'Declined' : 'Pending') ?>: <?php echo $user->firstName . ' ' . $user->lastName ?> |
|
94 | 94 | </h2> |
95 | 95 | </div> |
96 | 96 | <div class="box-body"> |
@@ -131,7 +131,7 @@ discard block |
||
131 | 131 | <?php |
132 | 132 | $users = allUsersNames(); |
133 | 133 | foreach ($users as $existingUser): ?> |
134 | - <option value="<?php echo $existingUser->id?>" <?php echo($existingUser->firstName == $user->firstName) && ($existingUser->lastName == $user->lastName) ? "selected='selected'" : '' ?>><?php echo $existingUser->firstName.' '.$existingUser->lastName ?></option> |
|
134 | + <option value="<?php echo $existingUser->id?>" <?php echo($existingUser->firstName == $user->firstName) && ($existingUser->lastName == $user->lastName) ? "selected='selected'" : '' ?>><?php echo $existingUser->firstName . ' ' . $existingUser->lastName ?></option> |
|
135 | 135 | <?php endforeach; ?> |
136 | 136 | </select> |
137 | 137 | </div> |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | exit; |
34 | 34 | } |
35 | 35 | if (!isAdmin()) { |
36 | - header('Location: error.php?no=100&page='.basename($_SERVER['SCRIPT_FILENAME'])); |
|
36 | + header('Location: error.php?no=100&page=' . basename($_SERVER['SCRIPT_FILENAME'])); |
|
37 | 37 | exit; |
38 | 38 | } |
39 | 39 | |
@@ -165,7 +165,7 @@ discard block |
||
165 | 165 | skin='$skin'"; |
166 | 166 | |
167 | 167 | if (!mysqli_query(db(), $sql)) { |
168 | - die('Error: '.mysqli_error(db())); |
|
168 | + die('Error: ' . mysqli_error(db())); |
|
169 | 169 | } |
170 | 170 | header('Location: settings.php'); |
171 | 171 | } |
@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | <!-- Content Header (Page header) --> |
193 | 193 | <section class="content-header"> |
194 | 194 | <h1>Settings |
195 | - <?php echo '<small>v'.$row['version'].'</small>'; ?> |
|
195 | + <?php echo '<small>v' . $row['version'] . '</small>'; ?> |
|
196 | 196 | </h1> |
197 | 197 | <ol class="breadcrumb"> |
198 | 198 | <li><a href="<?php echo siteSettings()->getSiteUrl() ?>"><i class="fa fa-dashboard"></i> Home</a></li> |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | } catch (\Exception $e) { |
35 | 35 | } |
36 | 36 | |
37 | -$url = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http').'://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']; |
|
37 | +$url = (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http') . '://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; |
|
38 | 38 | $url = substr($url, 0, -12); // remove "/install.php" from url |
39 | 39 | |
40 | 40 | if ($_SERVER['REQUEST_METHOD'] == 'POST') { |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | //exit; |
49 | 49 | $conn->exec($sql); |
50 | 50 | } catch (\Exception $e) { |
51 | - echo 'Error (code: '.$e->getCode().') adding tables to database: '.$e->getMessage(); |
|
51 | + echo 'Error (code: ' . $e->getCode() . ') adding tables to database: ' . $e->getMessage(); |
|
52 | 52 | exit; |
53 | 53 | } |
54 | 54 | |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | $lastname = $_POST['lastname']; |
59 | 59 | $lastname = trim(strip_tags($lastname)); |
60 | 60 | |
61 | - $username = strtolower($firstname).'.'.strtolower($lastname); |
|
61 | + $username = strtolower($firstname) . '.' . strtolower($lastname); |
|
62 | 62 | |
63 | 63 | $password = $_POST['password']; |
64 | 64 | |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | try { |
83 | 83 | $user->save(); |
84 | 84 | } catch (\Exception $e) { |
85 | - echo 'Error (code: '.$e->getCode().') adding user to database: '.$e->getMessage(); |
|
85 | + echo 'Error (code: ' . $e->getCode() . ') adding user to database: ' . $e->getMessage(); |
|
86 | 86 | exit; |
87 | 87 | } |
88 | 88 | |
@@ -179,7 +179,7 @@ discard block |
||
179 | 179 | |
180 | 180 | $settings->save(); |
181 | 181 | |
182 | - header('Location: login.php?username='.$username); // Move to the home page of the admin section |
|
182 | + header('Location: login.php?username=' . $username); // Move to the home page of the admin section |
|
183 | 183 | exit; |
184 | 184 | } |
185 | 185 |
@@ -2,6 +2,6 @@ |
||
2 | 2 | |
3 | 3 | namespace TechWilk\Rota; |
4 | 4 | |
5 | -ini_set('display_errors', false); // set on for development, off for production |
|
5 | +ini_set('display_errors', false); // set on for development, off for production |
|
6 | 6 | ini_set('log_errors', true); |
7 | 7 | error_reporting(E_ALL); |
@@ -6,16 +6,16 @@ discard block |
||
6 | 6 | use Monolog\Handler\StreamHandler; |
7 | 7 | use Monolog\Logger; |
8 | 8 | |
9 | -include __DIR__.'/errors.php'; |
|
9 | +include __DIR__ . '/errors.php'; |
|
10 | 10 | |
11 | 11 | // setup the autoloading |
12 | -require_once dirname(__FILE__).'/../../../vendor/autoload.php'; |
|
12 | +require_once dirname(__FILE__) . '/../../../vendor/autoload.php'; |
|
13 | 13 | |
14 | 14 | // setup Propel |
15 | -require_once dirname(__FILE__).'/../../../generated-conf/config.php'; |
|
15 | +require_once dirname(__FILE__) . '/../../../generated-conf/config.php'; |
|
16 | 16 | |
17 | 17 | $defaultLogger = new Logger('defaultLogger'); |
18 | -$defaultLogger->pushHandler(new StreamHandler(__DIR__.'/../../../logs/propel.log', Logger::WARNING)); |
|
18 | +$defaultLogger->pushHandler(new StreamHandler(__DIR__ . '/../../../logs/propel.log', Logger::WARNING)); |
|
19 | 19 | |
20 | 20 | $serviceContainer->setLogger('defaultLogger', $defaultLogger); |
21 | 21 | |
@@ -64,18 +64,18 @@ discard block |
||
64 | 64 | return SettingsQuery::create()->findOne(); |
65 | 65 | } |
66 | 66 | |
67 | -include __DIR__.'/functions.auth.php'; |
|
68 | -include __DIR__.'/functions.notifications.php'; |
|
69 | -include __DIR__.'/functions.mail.php'; |
|
70 | -include __DIR__.'/functions.remove.php'; |
|
71 | -include __DIR__.'/functions.discussion.php'; |
|
72 | -include __DIR__.'/functions.event.php'; |
|
73 | -include __DIR__.'/functions.password.php'; |
|
74 | -include __DIR__.'/functions.users.php'; |
|
75 | -include __DIR__.'/functions.roles.php'; |
|
76 | -include __DIR__.'/functions.database.php'; |
|
77 | -include __DIR__.'/functions.calendars.php'; |
|
78 | -include __DIR__.'/functions.facebook.php'; |
|
67 | +include __DIR__ . '/functions.auth.php'; |
|
68 | +include __DIR__ . '/functions.notifications.php'; |
|
69 | +include __DIR__ . '/functions.mail.php'; |
|
70 | +include __DIR__ . '/functions.remove.php'; |
|
71 | +include __DIR__ . '/functions.discussion.php'; |
|
72 | +include __DIR__ . '/functions.event.php'; |
|
73 | +include __DIR__ . '/functions.password.php'; |
|
74 | +include __DIR__ . '/functions.users.php'; |
|
75 | +include __DIR__ . '/functions.roles.php'; |
|
76 | +include __DIR__ . '/functions.database.php'; |
|
77 | +include __DIR__ . '/functions.calendars.php'; |
|
78 | +include __DIR__ . '/functions.facebook.php'; |
|
79 | 79 | |
80 | 80 | date_default_timezone_set(siteSettings()->getTimeZone()); |
81 | 81 | |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | $stat_id = $_SESSION['login_statistic_id']; |
176 | 176 | if (($stat_id != '') && ($stat_id != '0')) { |
177 | 177 | $stat = StatisticQuery::create()->findPk($stat_id); |
178 | - $stat->setDetail1($stat->getDetail1().'/'.$detail1); |
|
178 | + $stat->setDetail1($stat->getDetail1() . '/' . $detail1); |
|
179 | 179 | $stat->setDetail2($stat->getDate()->diff(new DateTime())); |
180 | 180 | $stat->save(); |
181 | 181 | |
@@ -208,7 +208,7 @@ discard block |
||
208 | 208 | return 'never'; |
209 | 209 | } |
210 | 210 | |
211 | - return timeInWords($time).' ago'; |
|
211 | + return timeInWords($time) . ' ago'; |
|
212 | 212 | } |
213 | 213 | |
214 | 214 | function timeInWordsWithTense($time) |
@@ -222,9 +222,9 @@ discard block |
||
222 | 222 | } |
223 | 223 | |
224 | 224 | if ($time->getTimestamp() > (new DateTime())->getTimestamp()) { |
225 | - return 'in '.timeInWords($time); |
|
225 | + return 'in ' . timeInWords($time); |
|
226 | 226 | } else { |
227 | - return timeInWords($time).' ago'; |
|
227 | + return timeInWords($time) . ' ago'; |
|
228 | 228 | } |
229 | 229 | } |
230 | 230 |
@@ -2,10 +2,10 @@ discard block |
||
2 | 2 | |
3 | 3 | namespace TechWilk\Rota; |
4 | 4 | |
5 | -include __DIR__.'/../../../config/database.php'; |
|
6 | -include __DIR__.'/../../../config/auth.php'; |
|
7 | -include __DIR__.'/../../../config/email.php'; |
|
8 | -include __DIR__.'/../../../config/recording.php'; |
|
5 | +include __DIR__ . '/../../../config/database.php'; |
|
6 | +include __DIR__ . '/../../../config/auth.php'; |
|
7 | +include __DIR__ . '/../../../config/email.php'; |
|
8 | +include __DIR__ . '/../../../config/recording.php'; |
|
9 | 9 | |
10 | 10 | // -- Setup database -- |
11 | 11 | |
@@ -17,10 +17,10 @@ discard block |
||
17 | 17 | } |
18 | 18 | |
19 | 19 | // Connect to the database server |
20 | -$dbh = @mysqli_connect($config['db']['host'], $config['db']['user'], $config['db']['pass']) or die('Connection to '.$config['db']['host']." with login '".$config['db']['user']."'/'$pwdMasked' failed."); |
|
20 | +$dbh = @mysqli_connect($config['db']['host'], $config['db']['user'], $config['db']['pass']) or die('Connection to ' . $config['db']['host'] . " with login '" . $config['db']['user'] . "'/'$pwdMasked' failed."); |
|
21 | 21 | |
22 | 22 | // Choose the right database |
23 | -$db = @mysqli_select_db($dbh, $config['db']['dbname']) or die("Connection made, but database '".$config['db']['dbname']."' was not found."); |
|
23 | +$db = @mysqli_select_db($dbh, $config['db']['dbname']) or die("Connection made, but database '" . $config['db']['dbname'] . "' was not found."); |
|
24 | 24 | |
25 | 25 | // allow config to be fetched in functions |
26 | 26 |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | } |
36 | 36 | |
37 | 37 | // create username and remove all whitespace |
38 | - $username = $firstNameLower.'.'.$lastNameLower; |
|
38 | + $username = $firstNameLower . '.' . $lastNameLower; |
|
39 | 39 | $username = preg_replace('/\s+/', '', $username); |
40 | 40 | |
41 | 41 | $sql = ("INSERT INTO cr_users (firstName, lastName, username, email, mobile, password, created, updated) |
@@ -46,12 +46,12 @@ discard block |
||
46 | 46 | $id = mysqli_insert_id(db()); |
47 | 47 | |
48 | 48 | $notificationMessage = "Welcome to your new account on the rota system.\n |
49 | -If you have any issues, please get in touch with us [".siteSettings()->getAdminEmailAddress().'](mailto:'.siteSettings()->getAdminEmailAddress().").\n |
|
49 | +If you have any issues, please get in touch with us [".siteSettings()->getAdminEmailAddress() . '](mailto:' . siteSettings()->getAdminEmailAddress() . ").\n |
|
50 | 50 | ---\n |
51 | 51 | **Sync to digital calendar**\n |
52 | 52 | You may wish to link the rota to your digital calendar on your computer and phone. To do so, generate a [calendar token](calendarTokens.php) which will present you with your unique URL. Follow instructions from your digital calendar provider for exact details on how import an iCal feed, or get in touch and we may be able to help.\n"; |
53 | 53 | |
54 | - createNotificationForUser($id, 'Welcome '.$firstName, $notificationMessage, 'feature'); |
|
54 | + createNotificationForUser($id, 'Welcome ' . $firstName, $notificationMessage, 'feature'); |
|
55 | 55 | createNotificationForUser($id, 'Change your password', 'Please change your password to something unique and memorable.', 'account', 'editPassword.php'); |
56 | 56 | |
57 | 57 | return $id; |
@@ -145,7 +145,7 @@ discard block |
||
145 | 145 | $sql = "SELECT firstName, lastName FROM cr_users WHERE id = '$id'"; |
146 | 146 | $result = mysqli_query(db(), $sql) or die(mysqli_error(db())); |
147 | 147 | $ob = mysqli_fetch_object($result); |
148 | - $name = $ob->firstName.' '.$ob->lastName; |
|
148 | + $name = $ob->firstName . ' ' . $ob->lastName; |
|
149 | 149 | |
150 | 150 | return $name; |
151 | 151 | } |
@@ -219,7 +219,7 @@ discard block |
||
219 | 219 | $currentTimestamp = date('Y-m-d H:i:s'); |
220 | 220 | $sql = "UPDATE cr_users SET password = '$newPassword', passwordChanged = '$currentTimestamp' WHERE id = '$userId'"; |
221 | 221 | $result = mysqli_query(db(), $sql) or die(mysqli_error(db())); |
222 | - insertStatistics('user', __FILE__, 'password force changed for user '.getNameWithId($userId), null, $_SERVER['HTTP_USER_AGENT']); |
|
222 | + insertStatistics('user', __FILE__, 'password force changed for user ' . getNameWithId($userId), null, $_SERVER['HTTP_USER_AGENT']); |
|
223 | 223 | } |
224 | 224 | |
225 | 225 | function hashPassword($plainTextPassword) |
@@ -264,7 +264,7 @@ discard block |
||
264 | 264 | if ($loginFailures < $numberOfAllowedAttempts) { |
265 | 265 | return true; |
266 | 266 | } else { |
267 | - insertStatistics('user', __FILE__, 'Login attempts exceeded for username: '.$username, $ipAddress, $_SERVER['HTTP_USER_AGENT']); |
|
267 | + insertStatistics('user', __FILE__, 'Login attempts exceeded for username: ' . $username, $ipAddress, $_SERVER['HTTP_USER_AGENT']); |
|
268 | 268 | |
269 | 269 | return false; |
270 | 270 | } |
@@ -340,11 +340,11 @@ discard block |
||
340 | 340 | $result = mysqli_query(db(), $sql) or die(mysqli_error(db())); |
341 | 341 | |
342 | 342 | $pendingId = mysqli_insert_id(db()); |
343 | - $linkToApprove = 'pendingAccounts.php?id='.$pendingId; |
|
343 | + $linkToApprove = 'pendingAccounts.php?id=' . $pendingId; |
|
344 | 344 | |
345 | - $email = siteSettings()->getOwner().'<'.siteSettings()->getAdminEmailAddress().'>'; |
|
346 | - $subject = $firstName.' requested an account'; |
|
347 | - $message = $subject.' through '.$source.".\nApprove or decline: ".siteSettings()->getSiteUrl().'/'.$linkToApprove; |
|
345 | + $email = siteSettings()->getOwner() . '<' . siteSettings()->getAdminEmailAddress() . '>'; |
|
346 | + $subject = $firstName . ' requested an account'; |
|
347 | + $message = $subject . ' through ' . $source . ".\nApprove or decline: " . siteSettings()->getSiteUrl() . '/' . $linkToApprove; |
|
348 | 348 | |
349 | 349 | sendMail($email, $subject, $message, $email); |
350 | 350 | |
@@ -416,7 +416,7 @@ discard block |
||
416 | 416 | addSocialAuthToUserWithId($userId, $pendingUser->socialId, $pendingUser->source); |
417 | 417 | updateUser($userId, $pendingUser->firstName, $pendingUser->lastName, $pendingUser->email, null); |
418 | 418 | |
419 | - createNotificationForUser($userId, 'Social Login added: '.$pendingUser->source, 'Your social media login details for '.$pendingUser->source.' have been added to your existing account', 'account'); |
|
419 | + createNotificationForUser($userId, 'Social Login added: ' . $pendingUser->source, 'Your social media login details for ' . $pendingUser->source . ' have been added to your existing account', 'account'); |
|
420 | 420 | createFacebookNotificationForUser($userId, 'login.php', 'Your account request has been approved. You can now login via Facebook.'); |
421 | 421 | |
422 | 422 | return true; |
@@ -499,32 +499,32 @@ discard block |
||
499 | 499 | |
500 | 500 | function getProfileImageUrl($userId, $size = 'small') |
501 | 501 | { |
502 | - $sql = 'SELECT sa.socialId, u.email FROM cr_users u LEFT JOIN cr_socialAuth sa ON sa.userId = u.id WHERE id = '.$userId; |
|
502 | + $sql = 'SELECT sa.socialId, u.email FROM cr_users u LEFT JOIN cr_socialAuth sa ON sa.userId = u.id WHERE id = ' . $userId; |
|
503 | 503 | $result = mysqli_query(db(), $sql) or die(mysqli_error(db())); |
504 | 504 | $user = mysqli_fetch_object($result); |
505 | 505 | |
506 | 506 | if ($user->socialId) { |
507 | 507 | switch ($size) { |
508 | 508 | case 'small': // 50px x 50px |
509 | - return '//graph.facebook.com/'.$user->socialId.'/picture?type=square'; |
|
509 | + return '//graph.facebook.com/' . $user->socialId . '/picture?type=square'; |
|
510 | 510 | break; |
511 | 511 | case 'large': // 200px x 200px |
512 | - return '//graph.facebook.com/'.$user->socialId.'/picture?type=large'; |
|
512 | + return '//graph.facebook.com/' . $user->socialId . '/picture?type=large'; |
|
513 | 513 | break; |
514 | 514 | default: |
515 | - return '//graph.facebook.com/'.$user->socialId.'/picture'; |
|
515 | + return '//graph.facebook.com/' . $user->socialId . '/picture'; |
|
516 | 516 | break; |
517 | 517 | } |
518 | 518 | } else { |
519 | 519 | switch ($size) { |
520 | 520 | case 'small': // 50px x 50px |
521 | - return '//www.gravatar.com/avatar/'.md5(strtolower(trim($user->email))).'?s=50&d=mm'; |
|
521 | + return '//www.gravatar.com/avatar/' . md5(strtolower(trim($user->email))) . '?s=50&d=mm'; |
|
522 | 522 | break; |
523 | 523 | case 'large': // 200px x 200px |
524 | - return '//www.gravatar.com/avatar/'.md5(strtolower(trim($user->email))).'?s=200&d=mm'; |
|
524 | + return '//www.gravatar.com/avatar/' . md5(strtolower(trim($user->email))) . '?s=200&d=mm'; |
|
525 | 525 | break; |
526 | 526 | default: |
527 | - return '//www.gravatar.com/avatar/'.md5(strtolower(trim($user->email))).'?s=50&d=mm'; |
|
527 | + return '//www.gravatar.com/avatar/' . md5(strtolower(trim($user->email))) . '?s=50&d=mm'; |
|
528 | 528 | break; |
529 | 529 | } |
530 | 530 | } |