@@ -43,10 +43,10 @@ discard block |
||
43 | 43 | credit_to_ops($credit, $ops, $unit); |
44 | 44 | |
45 | 45 | if ($bolden) { |
46 | - $lbold="[["; |
|
47 | - $rbold="]]"; |
|
46 | + $lbold = "[["; |
|
47 | + $rbold = "]]"; |
|
48 | 48 | } else { |
49 | - $lbold=""; $rbold=""; |
|
49 | + $lbold = ""; $rbold = ""; |
|
50 | 50 | } |
51 | 51 | return " $lbold$cobbs Cobblestones$rbold of computation ($ops $unit floating-point operations)"; |
52 | 52 | } |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | // |
87 | 87 | function show_share_buttons() { |
88 | 88 | echo '<p>'; |
89 | - $current_url = (empty($_SERVER['HTTPS']) ? 'http' : 'https') . "://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; |
|
89 | + $current_url = (empty($_SERVER['HTTPS']) ? 'http' : 'https')."://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"; |
|
90 | 90 | $cert_url = urlencode($current_url); |
91 | 91 | |
92 | 92 | // Share on Facebook |
@@ -27,10 +27,10 @@ discard block |
||
27 | 27 | if (DISABLE_TEAMS) error_page("Teams are disabled"); |
28 | 28 | |
29 | 29 | $border = get_str("border", true); |
30 | -if ($border=="no") { |
|
31 | - $border=0; |
|
30 | +if ($border == "no") { |
|
31 | + $border = 0; |
|
32 | 32 | } else { |
33 | - $border=8; |
|
33 | + $border = 8; |
|
34 | 34 | } |
35 | 35 | |
36 | 36 | // Make sure user_id is in the URL so that share functions work |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | if (!$user_id) { |
40 | 40 | $user = get_logged_in_user(); |
41 | 41 | Header(sprintf('Location: %s/cert_team.php?user_id=%d%s', |
42 | - url_base(), $user->id, $border==0?'&border=no':'' |
|
42 | + url_base(), $user->id, $border == 0 ? '&border=no' : '' |
|
43 | 43 | )); |
44 | 44 | exit; |
45 | 45 | } |
@@ -24,10 +24,10 @@ discard block |
||
24 | 24 | require_once("../inc/cert.inc"); |
25 | 25 | |
26 | 26 | $border = get_str("border", true); |
27 | -if ($border=="no") { |
|
28 | - $border=0; |
|
27 | +if ($border == "no") { |
|
28 | + $border = 0; |
|
29 | 29 | } else { |
30 | - $border=8; |
|
30 | + $border = 8; |
|
31 | 31 | } |
32 | 32 | |
33 | 33 | // Make sure user_id is in the URL so that share functions work |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | if (!$user_id) { |
37 | 37 | $user = get_logged_in_user(); |
38 | 38 | Header(sprintf('Location: %s/cert1.php?user_id=%d%s', |
39 | - url_base(), $user->id, $border==0?'&border=no':'' |
|
39 | + url_base(), $user->id, $border == 0 ? '&border=no' : '' |
|
40 | 40 | )); |
41 | 41 | exit; |
42 | 42 | } |
@@ -25,10 +25,10 @@ discard block |
||
25 | 25 | require_once("../inc/user.inc"); |
26 | 26 | |
27 | 27 | $border = get_str("border", true); |
28 | -if ($border=="no") { |
|
29 | - $border=0; |
|
28 | +if ($border == "no") { |
|
29 | + $border = 0; |
|
30 | 30 | } else { |
31 | - $border=8; |
|
31 | + $border = 8; |
|
32 | 32 | } |
33 | 33 | |
34 | 34 | // Make sure user_id is in the URL so that share functions work |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | if (!$user_id) { |
38 | 38 | $user = get_logged_in_user(); |
39 | 39 | Header(sprintf('Location: %s/cert_all.php?user_id=%d%s', |
40 | - url_base(), $user->id, $border==0?'&border=no':'' |
|
40 | + url_base(), $user->id, $border == 0 ? '&border=no' : '' |
|
41 | 41 | )); |
42 | 42 | exit; |
43 | 43 | } |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | <tr><th align=left>Project</th><th align=left>Cobblestones</th><th align=left>Joined</th></tr> |
92 | 92 | "; |
93 | 93 | foreach ($user->projects as $p) { |
94 | - if ($p->total_credit<100) continue; |
|
94 | + if ($p->total_credit < 100) continue; |
|
95 | 95 | show_proj($p); |
96 | 96 | } |
97 | 97 | echo " |