Passed
Push — master ( 4bf09c...a2eb0f )
by Maja
08:36
created
web/user/sb_download.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
  * @author Stefan Winter <[email protected]>
28 28
  * @package UserGUI
29 29
  */
30
-require dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
30
+require dirname(dirname(dirname(__FILE__)))."/config/_config.php";
31 31
 $API = new \core\UserAPI();
32 32
 $loggerInstance = new \core\common\Logging();
33 33
 $validator = new \web\lib\common\InputValidation();
@@ -76,6 +76,6 @@  discard block
 block discarded – undo
76 76
     if ($accountPageUrl === FALSE) {
77 77
         throw new Exception("Unable to find our accountstatus.php page.");
78 78
     }
79
-    header("Location: ../accountstatus/accountstatus.php?token=" . $cleanToken . "&errorcode=GENERATOR_CONSUMED");
79
+    header("Location: ../accountstatus/accountstatus.php?token=".$cleanToken."&errorcode=GENERATOR_CONSUMED");
80 80
     throw $e;
81 81
 }
Please login to merge, or discard this patch.
web/user/API.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
  *
25 25
  * @package UserAPI
26 26
  */
27
-require dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
27
+require dirname(dirname(dirname(__FILE__)))."/config/_config.php";
28 28
 $API = new \core\UserNetAPI();
29 29
 $validator = new web\lib\common\InputValidation();
30 30
 $loggerInstance = new \core\common\Logging();
Please login to merge, or discard this patch.
web/user/tou.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-        $Tou =  [
22
+        $Tou = [
23 23
     'title' => _("Terms of Use"),
24 24
     'subtitle' => _("(for legal reasons, the Terms of Use are in English only)"),
25 25
     'short' => "<p>The purpose of this service is to make eduroam configuration easier for end users and eduroam
Please login to merge, or discard this patch.
web/admin/overview_federation.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -311,8 +311,8 @@
 block discarded – undo
311 311
                             echo "<form method='post' action='overview_federation.php' accept-charset='UTF-8'>
312 312
                                 <input type='hidden' name='invitation_id' value='" . $oneinvite['token'] . "'/>
313 313
                                 <button class='delete' type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_DELETE . "'>" . _("Revoke Invitation") . "</button> "
314
-                              . sprintf(_("(expires %s)"),$oneinvite['expiry'])
315
-                              .     "</form>";
314
+                                . sprintf(_("(expires %s)"),$oneinvite['expiry'])
315
+                                .     "</form>";
316 316
                         }
317 317
                         echo "      </td>
318 318
                                  </tr>";
Please login to merge, or discard this patch.
Spacing   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
22
+require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php";
23 23
 
24 24
 $deco = new \web\lib\admin\PageDecoration();
25 25
 $uiElements = new web\lib\admin\UIElements();
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
             <?php echo $uiElements->infoblock($user->getAttributes(), "user", "User"); ?>
48 48
             <tr>
49 49
                 <td>
50
-                    <?php echo "" . _("Unique Identifier") ?>
50
+                    <?php echo ""._("Unique Identifier") ?>
51 51
                 </td>
52 52
                 <td>
53 53
                 </td>
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
     $mgmt = new \core\UserManagement();
63 63
 
64 64
     if (!$user->isFederationAdmin()) {
65
-        echo "<p>" . sprintf(_("You are not a %s manager."), $uiElements->nomenclatureFed) . "</p>";
65
+        echo "<p>".sprintf(_("You are not a %s manager."), $uiElements->nomenclatureFed)."</p>";
66 66
         echo $deco->footer();
67 67
         exit(0);
68 68
     }
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
                 <!-- fed properties -->
80 80
                 <tr>
81 81
                     <td>
82
-                        <?php echo "" . _("Country") ?>
82
+                        <?php echo ""._("Country") ?>
83 83
                     </td>
84 84
                     <td>
85 85
                     </td>
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
                     default:
161 161
                         throw new Exception("Error: unknown encryption status of invitation!?!");
162 162
                 }
163
-                echo $uiElements->boxRemark(ngettext("The invitation email was sent successfully.", "All invitation emails were sent successfully.", $counter) . " " . $cryptText, _("Sent successfully."));
163
+                echo $uiElements->boxRemark(ngettext("The invitation email was sent successfully.", "All invitation emails were sent successfully.", $counter)." ".$cryptText, _("Sent successfully."));
164 164
                 break;
165 165
             case "FAILURE":
166 166
                 echo $uiElements->boxError(_("No invitation email could be sent!"), _("Sending failure!"));
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
                     default:
181 181
                         throw new Exception("Error: unknown encryption status of invitation!?!");
182 182
                 }
183
-                echo $uiElements->boxWarning(sprintf(_("Some invitation emails were sent successfully (%s in total), the others failed."), $counter) . " " . $cryptText, _("Partial success."));
183
+                echo $uiElements->boxWarning(sprintf(_("Some invitation emails were sent successfully (%s in total), the others failed."), $counter)." ".$cryptText, _("Partial success."));
184 184
                 break;
185 185
             case "INVALIDSYNTAX":
186 186
                 echo $uiElements->boxError(_("The invitation email address was malformed, no invitation was sent!"), _("The invitation email address was malformed, no invitation was sent!"));
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
         echo "</table></div>";
192 192
     }
193 193
     if (\config\ConfAssistant::CONSORTIUM['name'] == 'eduroam') {
194
-        $helptext = "<h3>" . sprintf(_("Need help? Refer to the <a href='%s'>%s manual</a>"), "https://wiki.geant.org/x/fgBwBg", $uiElements->nomenclatureFed) . "</h3>";
194
+        $helptext = "<h3>".sprintf(_("Need help? Refer to the <a href='%s'>%s manual</a>"), "https://wiki.geant.org/x/fgBwBg", $uiElements->nomenclatureFed)."</h3>";
195 195
     } else {
196 196
         $helptext = "";
197 197
     }
@@ -205,7 +205,7 @@  discard block
 block discarded – undo
205 205
             $pending_invites = $mgmt->listPendingInvitations();
206 206
 
207 207
             if (\config\Master::DB['enforce-external-sync']) {
208
-                echo "<th>" . sprintf(_("%s Database Sync Status"), \config\ConfAssistant::CONSORTIUM['display_name']) . "</th>";
208
+                echo "<th>".sprintf(_("%s Database Sync Status"), \config\ConfAssistant::CONSORTIUM['display_name'])."</th>";
209 209
             }
210 210
             ?>
211 211
             <th>
@@ -220,7 +220,7 @@  discard block
 block discarded – undo
220 220
         foreach ($feds as $onefed) {
221 221
             $thefed = new \core\Federation(strtoupper($onefed['value']));
222 222
             /// nomenclature for 'federation', federation name, nomenclature for 'inst'
223
-            echo "<tr><td colspan='8'><strong>" . sprintf(_("The following %s are in your %s %s:"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed, '<span style="color:green">' . $thefed->name . '</span>') . "</strong></td></tr>";
223
+            echo "<tr><td colspan='8'><strong>".sprintf(_("The following %s are in your %s %s:"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed, '<span style="color:green">'.$thefed->name.'</span>')."</strong></td></tr>";
224 224
 
225 225
             // extract only pending invitations for *this* fed
226 226
             $display_pendings = FALSE;
@@ -245,27 +245,27 @@  discard block
 block discarded – undo
245 245
                 // deployment status; need to dive into profiles for this
246 246
                 // show happy eyeballs if at least one profile is configured/showtime                    
247 247
                 echo "<td>";
248
-                echo ($idp_instance->maxProfileStatus() >= \core\IdP::PROFILES_CONFIGURED ? "C" : "" ) . " " . ($idp_instance->maxProfileStatus() >= \core\IdP::PROFILES_SHOWTIME ? "V" : "" );
248
+                echo ($idp_instance->maxProfileStatus() >= \core\IdP::PROFILES_CONFIGURED ? "C" : "")." ".($idp_instance->maxProfileStatus() >= \core\IdP::PROFILES_SHOWTIME ? "V" : "");
249 249
                 echo "</td>";
250 250
                 // name
251 251
                 echo "<td>
252
-                         <input type='hidden' name='inst' value='" . $index . "'>" . $idp_instance->name . "
252
+                         <input type='hidden' name='inst' value='" . $index."'>".$idp_instance->name."
253 253
                       </td>";
254 254
                 // external DB sync, if configured as being necessary
255 255
                 if (\config\Master::DB['enforce-external-sync']) {
256 256
                     echo "<td style='display: ruby;'>";
257 257
                     if ($readonly === FALSE) {
258
-                        echo "<form method='post' action='inc/manageDBLink.inc.php?inst_id=" . $idp_instance->identifier . "' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
259
-                                    <button type='submit'>" . _("Manage DB Link") . "</button></form>&nbsp;&nbsp;";
258
+                        echo "<form method='post' action='inc/manageDBLink.inc.php?inst_id=".$idp_instance->identifier."' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
259
+                                    <button type='submit'>" . _("Manage DB Link")."</button></form>&nbsp;&nbsp;";
260 260
                     }
261 261
                     switch ($idp_instance->getExternalDBSyncState()) {
262 262
                         case \core\IdP::EXTERNAL_DB_SYNCSTATE_NOTSUBJECTTOSYNCING:
263 263
                             break;
264 264
                         case \core\IdP::EXTERNAL_DB_SYNCSTATE_SYNCED:
265
-                            echo "<div class='acceptable'>" . _("Linked") . "</div>";
265
+                            echo "<div class='acceptable'>"._("Linked")."</div>";
266 266
                             break;
267 267
                         case \core\IdP::EXTERNAL_DB_SYNCSTATE_NOT_SYNCED:
268
-                            echo "<div class='notacceptable'>" . _("NOT linked") . "</div>";
268
+                            echo "<div class='notacceptable'>"._("NOT linked")."</div>";
269 269
 
270 270
 
271 271
                             break;
@@ -278,9 +278,9 @@  discard block
 block discarded – undo
278 278
                 echo "<td>";
279 279
                 if ($readonly === FALSE) {
280 280
                     echo "<div style='white-space: nowrap;'>
281
-                                  <form method='post' action='inc/manageAdmins.inc.php?inst_id=" . $index . "' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
281
+                                  <form method='post' action='inc/manageAdmins.inc.php?inst_id=" . $index."' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
282 282
                                       <button type='submit'>" .
283
-                    _("Add/Remove Administrators") . "
283
+                    _("Add/Remove Administrators")."
284 284
                                       </button>
285 285
                                   </form>
286 286
                                 </div>";
@@ -293,7 +293,7 @@  discard block
 block discarded – undo
293 293
                 echo "<tr>
294 294
                             <td colspan='2'>
295 295
                                <strong>" .
296
-                sprintf(_("Pending invitations in the %s:"), $uiElements->nomenclatureFed) . "
296
+                sprintf(_("Pending invitations in the %s:"), $uiElements->nomenclatureFed)."
297 297
                                </strong>
298 298
                             </td>
299 299
                          </tr>";
@@ -301,17 +301,17 @@  discard block
 block discarded – undo
301 301
                     if (strtoupper($oneinvite['country']) == strtoupper($thefed->tld)) {
302 302
                         echo "<tr>
303 303
                                     <td>" .
304
-                        $oneinvite['name'] . "
304
+                        $oneinvite['name']."
305 305
                                     </td>
306 306
                                     <td>" .
307
-                        $oneinvite['mail'] . "
307
+                        $oneinvite['mail']."
308 308
                                     </td>
309 309
                                     <td colspan=2>";
310 310
                         if ($readonly === FALSE) {
311 311
                             echo "<form method='post' action='overview_federation.php' accept-charset='UTF-8'>
312
-                                <input type='hidden' name='invitation_id' value='" . $oneinvite['token'] . "'/>
313
-                                <button class='delete' type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_DELETE . "'>" . _("Revoke Invitation") . "</button> "
314
-                              . sprintf(_("(expires %s)"),$oneinvite['expiry'])
312
+                                <input type='hidden' name='invitation_id' value='" . $oneinvite['token']."'/>
313
+                                <button class='delete' type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_DELETE."'>"._("Revoke Invitation")."</button> "
314
+                              . sprintf(_("(expires %s)"), $oneinvite['expiry'])
315 315
                               .     "</form>";
316 316
                         }
317 317
                         echo "      </td>
Please login to merge, or discard this patch.
web/admin/edit_user.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
22
+require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php";
23 23
 
24 24
 $deco = new \web\lib\admin\PageDecoration();
25 25
 $uiElements = new web\lib\admin\UIElements();
Please login to merge, or discard this patch.
web/admin/inc/toggleRedirect.inc.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-require_once dirname(dirname(dirname(dirname(__FILE__)))) . "/config/_config.php";
22
+require_once dirname(dirname(dirname(dirname(__FILE__))))."/config/_config.php";
23 23
 
24 24
 $auth = new \web\lib\admin\Authentication();
25 25
 $loggerInstance = new \core\common\Logging();
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
         $remaining_attribs = $my_profile->beginFlushMethodLevelAttributes($eaptype->getIntegerRep(), NULL);
86 86
         $optionParser->processSubmittedFields($my_profile, $_POST, $_FILES, $eaptype->getIntegerRep(), NULL);
87 87
     }
88
-    $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile " . $my_profile->identifier . " - device/EAP-Type settings changed");
88
+    $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile ".$my_profile->identifier." - device/EAP-Type settings changed");
89 89
     header("Location: ../overview_installers.php?inst_id=$my_inst->identifier&profile_id=$my_profile->identifier");
90 90
     exit;
91 91
 }
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
     }
100 100
     $captiontext = sprintf(_("device <strong>%s</strong>"), $device['display']);
101 101
     $keyword = "device-specific";
102
-    $extrainput = "<input type='hidden' name='device' value='" . $device_key . "'/>";
102
+    $extrainput = "<input type='hidden' name='device' value='".$device_key."'/>";
103 103
 } elseif ($eaptype !== NULL) {
104 104
     foreach ($my_profile->getAttributes() as $attrib) {
105 105
         if (isset($attrib['eapmethod']) && $attrib['eapmethod'] == $eaptype->getArrayRep()) {
@@ -109,12 +109,12 @@  discard block
 block discarded – undo
109 109
 
110 110
     $captiontext = sprintf(_("EAP-Type <strong>%s</strong>"), $eaptype->getPrintableRep());
111 111
     $keyword = "eap-specific";
112
-    $extrainput = "<input type='hidden' name='eaptype' value='" . $eaptype->getIntegerRep() . "'>";
112
+    $extrainput = "<input type='hidden' name='eaptype' value='".$eaptype->getIntegerRep()."'>";
113 113
 } else {
114 114
     throw new Exception("previous type checks make it impossible to reach this code path.");
115 115
 }
116 116
 ?>
117
-<p><?php echo _("Fine-tuning options for ") . $captiontext; ?></p>
117
+<p><?php echo _("Fine-tuning options for ").$captiontext; ?></p>
118 118
 <hr/>
119 119
 
120 120
 <form action='inc/toggleRedirect.inc.php?inst_id=<?php echo $my_inst->identifier; ?>&amp;profile_id=<?php echo $my_profile->identifier; ?>' method='post' accept-charset='UTF-8'><?php echo $extrainput; ?>
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     $interesting_attribs = [];
124 124
 
125 125
     foreach ($attribs as $attrib) {
126
-        if ($attrib['level'] == "Method" && preg_match('/^' . $keyword . ':/', $attrib['name'])) {
126
+        if ($attrib['level'] == "Method" && preg_match('/^'.$keyword.':/', $attrib['name'])) {
127 127
             $interesting_attribs[] = $attrib;
128 128
         }
129 129
     }
Please login to merge, or discard this patch.
web/admin/inc/logout.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
  */
21 21
 ?>
22 22
 <?php
23
-require_once dirname(dirname(dirname(dirname(__FILE__)))) . "/config/_config.php";
23
+require_once dirname(dirname(dirname(dirname(__FILE__))))."/config/_config.php";
24 24
 
25 25
 $auth = new \web\lib\admin\Authentication();
26 26
 
Please login to merge, or discard this patch.
web/admin/inc/click_button_js.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-require_once dirname(dirname(dirname(dirname(__FILE__)))) . "/config/_config.php";
22
+require_once dirname(dirname(dirname(dirname(__FILE__))))."/config/_config.php";
23 23
 ?>
24 24
 
25 25
 <!-- JQuery --> 
Please login to merge, or discard this patch.
web/admin/overview_installers.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
  *          <base_url>/copyright.php after deploying the software
20 20
  */
21 21
 
22
-require_once dirname(dirname(__DIR__)) . "/config/_config.php";
22
+require_once dirname(dirname(__DIR__))."/config/_config.php";
23 23
 
24 24
 $deco = new \web\lib\admin\PageDecoration();
25 25
 $validator = new \web\lib\common\InputValidation();
@@ -53,10 +53,10 @@  discard block
 block discarded – undo
53 53
             <?php
54 54
             foreach ($preflist as $method) {
55 55
                 $escapedMethod = $method->getIntegerRep();
56
-                echo "<th style='min-width:200px'>" . $method->getPrintableRep() . "<br/>
56
+                echo "<th style='min-width:200px'>".$method->getPrintableRep()."<br/>
57 57
                         <form method='post' action='inc/toggleRedirect.inc.php?inst_id=$my_inst->identifier&amp;profile_id=$my_profile->identifier' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
58 58
                         <input type='hidden' name='eaptype' value='$escapedMethod'>
59
-                        <button class='redirect' type='submit'>" . _("EAP-Type-specific options...") . "</button>
59
+                        <button class='redirect' type='submit'>"._("EAP-Type-specific options...")."</button>
60 60
                         </form></th>";
61 61
             }
62 62
             ?>
@@ -72,10 +72,10 @@  discard block
 block discarded – undo
72 72
         foreach (\devices\Devices::listDevices() as $index => $description) {
73 73
 
74 74
             echo "<tr>";
75
-            echo "<td align='center'><img src='../resources/images/vendorlogo/" . $description['group'] . ".png' alt='logo'></td><td>" . $description['display'] . "<br/>
75
+            echo "<td align='center'><img src='../resources/images/vendorlogo/".$description['group'].".png' alt='logo'></td><td>".$description['display']."<br/>
76 76
                         <form method='post' action='inc/toggleRedirect.inc.php?inst_id=$my_inst->identifier&amp;profile_id=$my_profile->identifier' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'>
77 77
                         <input type='hidden' name='device' value='$index'>
78
-                        <button class='redirect' type='submit'>" . _("Device-specific options...") . "</button>
78
+                        <button class='redirect' type='submit'>"._("Device-specific options...")."</button>
79 79
                         </form>
80 80
                         </td>";
81 81
             $factory = new \core\DeviceFactory($index);
@@ -84,10 +84,10 @@  discard block
 block discarded – undo
84 84
                 $footnotesForDevEapCombo = [];
85 85
                 $display_footnote = FALSE;
86 86
                 $langObject = new \core\common\Language();
87
-                $downloadform = "<form action='" . rtrim(dirname(dirname($_SERVER['SCRIPT_NAME'])), '/') . "/user/API.php?action=downloadInstaller&profile=$my_profile->identifier&lang=" . $langObject->getLang() . "' method='post' accept-charset='UTF-8'>
87
+                $downloadform = "<form action='".rtrim(dirname(dirname($_SERVER['SCRIPT_NAME'])), '/')."/user/API.php?action=downloadInstaller&profile=$my_profile->identifier&lang=".$langObject->getLang()."' method='post' accept-charset='UTF-8'>
88 88
                                        <input type='hidden' name='device' value='$index'/>
89 89
                                        <input type='hidden' name='generatedfor'  value='admin'/>
90
-                                       <button class='download'>" . _("Download") . "</button>
90
+                                       <button class='download'>"._("Download")."</button>
91 91
                                      ";
92 92
                 // first of all: if redirected, indicate by color
93 93
 
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
     </table>
159 159
     <?php
160 160
     if (count($distinctFootnotes)) {
161
-        echo "<p><strong>" . _("Footnotes:") . "</strong></p><table>";
161
+        echo "<p><strong>"._("Footnotes:")."</strong></p><table>";
162 162
         foreach ($distinctFootnotes as $number => $text) {
163 163
             echo "<tr><td>($number) - </td><td>$text</td></tr>";
164 164
         }
Please login to merge, or discard this patch.