Test Setup Failed
Push — master ( 0dd6e1...79885b )
by Stefan
05:34
created
core/CAT.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -105,28 +105,28 @@
 block discarded – undo
105 105
         parent::__construct();
106 106
         common\Entity::intoThePotatoes();
107 107
 
108
-        $this->catVersionString = sprintf(_("Unreleased %s Git Revision"), "<a href='https://github.com/GEANT/CAT/tree/master/Changes.md'>") . "</a>";
108
+        $this->catVersionString = sprintf(_("Unreleased %s Git Revision"), "<a href='https://github.com/GEANT/CAT/tree/master/Changes.md'>")."</a>";
109 109
         if (CAT::RELEASE_VERSION) {
110 110
             $major = CAT::VERSION_MAJOR;
111 111
             $minor = CAT::VERSION_MINOR;
112 112
             $patch = CAT::VERSION_PATCH;
113 113
             $extra = CAT::VERSION_EXTRA;
114 114
             $temp_version = "CAT-$major.$minor";
115
-            $branch = "release_$major" . "_$minor";
115
+            $branch = "release_$major"."_$minor";
116 116
             if (CAT::VERSION_PATCH != 0) {
117 117
                 $temp_version .= ".$patch";
118 118
             }
119 119
             if (CAT::VERSION_EXTRA != "") {
120 120
                 $temp_version .= "-$extra";
121 121
             }
122
-            $this->catVersionString = sprintf(_("Release <a href='%s'>%s</a>"), "https://github.com/GEANT/CAT/tree/" . $branch . "/Changes.md", $temp_version);
122
+            $this->catVersionString = sprintf(_("Release <a href='%s'>%s</a>"), "https://github.com/GEANT/CAT/tree/".$branch."/Changes.md", $temp_version);
123 123
         }
124 124
         $product = \config\Master::APPEARANCE['productname'];
125 125
         $minYear = self::COPYRIGHT_MIN_YEAR;
126 126
         $maxYear = self::COPYRIGHT_MAX_YEAR;
127 127
         $holder = self::COPYRIGHT_HOLDER;
128 128
         $consortia = self::COPYRIGHT_CONSORTIA;
129
-        $this->catCopyright = "$product - " . $this->catVersionString . " &copy; $minYear-$maxYear $holder<br/>on behalf of $consortia; and others <a href='copyright.php'>Full Copyright and Licenses</a>";
129
+        $this->catCopyright = "$product - ".$this->catVersionString." &copy; $minYear-$maxYear $holder<br/>on behalf of $consortia; and others <a href='copyright.php'>Full Copyright and Licenses</a>";
130 130
 
131 131
 
132 132
         /* Federations are created in DB with bootstrapFederation, and listed via listFederations
Please login to merge, or discard this patch.
web/admin/sanity_tests.php 1 patch
Spacing   +2 added lines, -2 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
 $Tests = [
25 25
     'Directories',
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
 
44 44
 $uiElements = new \web\lib\admin\UIElements();
45 45
 
46
-if (\config\Master::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || \config\Master::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL" ) {
46
+if (\config\Master::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || \config\Master::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL") {
47 47
     $Tests[] = 'Makensis';
48 48
     $Tests[] = 'Makensis=>NSISmodules';
49 49
 }
Please login to merge, or discard this patch.
devices/Devices-template.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -397,7 +397,7 @@  discard block
 block discarded – undo
397 397
                     'mime' => 'application/eap-config',
398 398
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
399 399
                             "geteduroam",
400
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=app.eduroam.geteduroam'>Google Play</a>, <a target='_blank' href='geteduroam-stable.apk'>" . _("as local download") . "</a>"),
400
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=app.eduroam.geteduroam'>Google Play</a>, <a target='_blank' href='geteduroam-stable.apk'>"._("as local download")."</a>"),
401 401
                 ],
402 402
             ],            
403 403
             
@@ -411,7 +411,7 @@  discard block
 block discarded – undo
411 411
                     'mime' => 'application/eap-config',
412 412
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
413 413
                             "geteduroam",
414
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=app.eduroam.geteduroam'>Google Play</a>, <a target='_blank' href='geteduroam-stable.apk'>" . _("as local download") . "</a>"),
414
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=app.eduroam.geteduroam'>Google Play</a>, <a target='_blank' href='geteduroam-stable.apk'>"._("as local download")."</a>"),
415 415
                 ],
416 416
             ],  
417 417
             'android_4_7' => [
@@ -424,7 +424,7 @@  discard block
 block discarded – undo
424 424
                     'mime' => 'application/eap-config',
425 425
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
426 426
                             "eduroamCAT",
427
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
427
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
428 428
                 ],
429 429
             ],            
430 430
             
@@ -439,7 +439,7 @@  discard block
 block discarded – undo
439 439
                     'mime' => 'application/eap-config',
440 440
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
441 441
                             "eduroamCAT",
442
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
442
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
443 443
                 ],
444 444
             ],
445 445
             'android_pie' => [
@@ -453,7 +453,7 @@  discard block
 block discarded – undo
453 453
                     'mime' => 'application/eap-config',
454 454
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
455 455
                             "eduroamCAT",
456
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
456
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
457 457
                 ],
458 458
             ],
459 459
             'android_oreo' => [
@@ -467,7 +467,7 @@  discard block
 block discarded – undo
467 467
                     'mime' => 'application/eap-config',
468 468
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
469 469
                             "eduroamCAT",
470
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
470
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
471 471
                 ],
472 472
             ],
473 473
             'android_nougat' => [
@@ -481,7 +481,7 @@  discard block
 block discarded – undo
481 481
                     'mime' => 'application/eap-config',
482 482
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
483 483
                             "eduroamCAT",
484
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
484
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
485 485
                 ],
486 486
             ],
487 487
             'android_marshmallow' => [
@@ -495,7 +495,7 @@  discard block
 block discarded – undo
495 495
                     'mime' => 'application/eap-config',
496 496
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
497 497
                             "eduroamCAT",
498
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
498
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
499 499
                 ],
500 500
             ],
501 501
             'android_lollipop' => [
@@ -509,7 +509,7 @@  discard block
 block discarded – undo
509 509
                     'mime' => 'application/eap-config',
510 510
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
511 511
                             "eduroamCAT",
512
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
512
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
513 513
                 ],
514 514
             ],
515 515
             'android_kitkat' => [
@@ -523,7 +523,7 @@  discard block
 block discarded – undo
523 523
                     'mime' => 'application/eap-config',
524 524
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
525 525
                             "eduroamCAT",
526
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
526
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
527 527
                 ],
528 528
             ],
529 529
             'android_43' => [
@@ -537,7 +537,7 @@  discard block
 block discarded – undo
537 537
                     'mime' => 'application/eap-config',
538 538
                     'message' => sprintf(_("Before you proceed with installation on Android systems, please make sure that you have installed the %s application. This application is available from these sites: %s and will use the configuration file downloaded from CAT to create all necessary settings."),
539 539
                             "eduroamCAT",
540
-                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>" . _("as local download") . "</a>"),
540
+                            "<a target='_blank' href='https://play.google.com/store/apps/details?id=uk.ac.swansea.eduroamcat'>Google Play</a>, <a target='_blank' href='https://www.amazon.com/dp/B01EACCX0S/'>Amazon Appstore</a>, <a target='_blank' href='eduroamCAT-stable.apk'>"._("as local download")."</a>"),
541 541
                 ],
542 542
             ],
543 543
             'android_legacy' => [
Please login to merge, or discard this patch.
web/lib/user/TextTemplates.php 2 patches
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -89,12 +89,12 @@
 block discarded – undo
89 89
         $this->templates[WELCOME_ABOARD_TERMS] = "";
90 90
         foreach ([
91 91
                 "eduroam" => [ 
92
-                      "TOU"  => "https://wiki.geant.org/display/H2eduroam/Terms+and+Conditions",
93
-                      "PRIV" => "https://www.eduroam.org/privacy/",
92
+                        "TOU"  => "https://wiki.geant.org/display/H2eduroam/Terms+and+Conditions",
93
+                        "PRIV" => "https://www.eduroam.org/privacy/",
94 94
                     ], 
95 95
                 "OpenRoaming" => [ 
96
-                      "TOU"  => "https://wballiance.com/openroaming/toc-2020/",
97
-                      "PRIV" => "https://wballiance.com/openroaming/privacy-policy-2020/",
96
+                        "TOU"  => "https://wballiance.com/openroaming/toc-2020/",
97
+                        "PRIV" => "https://wballiance.com/openroaming/privacy-policy-2020/",
98 98
                     ]
99 99
             ] as $consortium => $terms) {
100 100
             $this->templates[WELCOME_ABOARD_TERMS] .= sprintf("<p>" . _("When connecting to %s hotspots, the following <a href='%s'>Terms and Conditions</a> and <a href='%s'>Privacy Notice</a> apply.") . "</p>", $consortium, $terms['TOU'], $terms['PRIV']);
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
 const DOWNLOAD_REDIRECT_CONTINUE = 1054;
50 50
 const SB_GO_AWAY = 1060;
51 51
 const SB_FRONTPAGE_BIGDOWNLOADBUTTON = 1061;
52
-const SB_FRONTPAGE_ROLLER_CUSTOMBUILT= 1062;
52
+const SB_FRONTPAGE_ROLLER_CUSTOMBUILT = 1062;
53 53
 
54 54
 
55 55
 /**
@@ -96,14 +96,14 @@  discard block
 block discarded – undo
96 96
                       "PRIV" => "https://wballiance.com/openroaming/privacy-policy-2020/",
97 97
                     ]
98 98
             ] as $consortium => $terms) {
99
-            $this->templates[WELCOME_ABOARD_TERMS] .= sprintf("<p>" . _("When connecting to %s hotspots, the following <a href='%s'>Terms and Conditions</a> and <a href='%s'>Privacy Notice</a> apply.") . "</p>", $consortium, $terms['TOU'], $terms['PRIV']);
99
+            $this->templates[WELCOME_ABOARD_TERMS] .= sprintf("<p>"._("When connecting to %s hotspots, the following <a href='%s'>Terms and Conditions</a> and <a href='%s'>Privacy Notice</a> apply.")."</p>", $consortium, $terms['TOU'], $terms['PRIV']);
100 100
         }
101 101
         // this would actually be a checkbox which grays out the actual download button until ACKed
102 102
         $this->templates[WELCOME_ABOARD_TERMS] .= "<p>"._("I agree to be bound by these Terms and Conditions.")."</p>";
103 103
         $this->templates[WELCOME_ABOARD_BACKTODOWNLOADS] = _("Back to downloads");
104 104
         $this->templates[EDUROAM_WELCOME_ADVERTISING] = sprintf(_("we would like to warmly welcome you among the several million users of %s! From now on, you will be able to use internet access resources on thousands of universities, research centres and other places all over the globe. All of this completely free of charge!"), \config\ConfAssistant::CONSORTIUM['display_name']);
105 105
         $this->templates[HEADING_TOPLEVEL_GREET] = sprintf(_("Welcome to %s"), \config\Master::APPEARANCE['productname']);
106
-        $this->templates[HEADING_TOPLEVEL_PURPOSE] = sprintf(_("Connect your device to %s"),\config\ConfAssistant::CONSORTIUM['display_name']);
106
+        $this->templates[HEADING_TOPLEVEL_PURPOSE] = sprintf(_("Connect your device to %s"), \config\ConfAssistant::CONSORTIUM['display_name']);
107 107
         $this->templates[FRONTPAGE_ROLLER_EASY] = sprintf(_("%s installation made easy:"), \config\ConfAssistant::CONSORTIUM['display_name']);
108 108
         $this->templates[FRONTPAGE_ROLLER_CUSTOMBUILT] = _("Custom built for your organisation");
109 109
         $this->templates[FRONTPAGE_BIGDOWNLOADBUTTON] = sprintf(_("Click here to download your %s installer"), \config\ConfAssistant::CONSORTIUM['display_name'], \config\ConfAssistant::CONSORTIUM['display_name']);
Please login to merge, or discard this patch.
core/IdPlist.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
         $allIDPs = ($country != "" ? $handle->exec($query, "s", $country) : $handle->exec($query));
69 69
         $returnarray = [];
70 70
         // SELECTs never return a booleans, always an object
71
-        $i=0;
71
+        $i = 0;
72 72
         while ($queryResult = mysqli_fetch_object(/** @scrutinizer ignore-type */ $allIDPs)) {
73 73
             $i++;
74 74
             $institutionOptions = explode('---', $queryResult->options);
Please login to merge, or discard this patch.
web/admin/edit_profile.php 1 patch
Spacing   +46 added lines, -46 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 
28 28
 ?>
29 29
 <?php
30
-require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
30
+require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php";
31 31
 
32 32
 $deco = new \web\lib\admin\PageDecoration();
33 33
 $validator = new \web\lib\common\InputValidation();
@@ -127,8 +127,8 @@  discard block
 block discarded – undo
127 127
     <?php
128 128
     echo $uiElements->instLevelInfoBoxes($my_inst);
129 129
 
130
-    echo "<form enctype='multipart/form-data' action='edit_profile_result.php?inst_id=$my_inst->identifier" . ($my_profile !== NULL ? "&amp;profile_id=" . $my_profile->identifier : "") . "' method='post' accept-charset='UTF-8'>
131
-                <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Master::MAX_UPLOAD_SIZE . "'>";
130
+    echo "<form enctype='multipart/form-data' action='edit_profile_result.php?inst_id=$my_inst->identifier".($my_profile !== NULL ? "&amp;profile_id=".$my_profile->identifier : "")."' method='post' accept-charset='UTF-8'>
131
+                <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Master::MAX_UPLOAD_SIZE."'>";
132 132
     $optionDisplay = new \web\lib\admin\OptionDisplay($profile_options, \core\Options::LEVEL_PROFILE);
133 133
     ?>
134 134
     <fieldset class="option_container">
@@ -137,29 +137,29 @@  discard block
 block discarded – undo
137 137
         </legend>
138 138
         <?php
139 139
         if ($wizardStyle) {
140
-            echo "<p>" . _("We will now define a profile for your user group(s).  You can add as many profiles as you like by choosing the appropriate button on the end of the page. After we are done, the wizard is finished and you will be taken to the main IdP administration page.") . "</p>";
140
+            echo "<p>"._("We will now define a profile for your user group(s).  You can add as many profiles as you like by choosing the appropriate button on the end of the page. After we are done, the wizard is finished and you will be taken to the main IdP administration page.")."</p>";
141 141
         }
142 142
         ?>
143 143
         <h3><?php echo _("Profile Name and RADIUS realm"); ?></h3>
144 144
         <?php
145 145
         if ($wizardStyle) {
146
-            echo "<p>" . _("First of all we need a name for the profile. This will be displayed to end users, so you may want to choose a descriptive name like 'Professors', 'Students of the Faculty of Bioscience', etc.") . "</p>";
147
-            echo "<p>" . _("Optionally, you can provide a longer descriptive text about who this profile is for. If you specify it, it will be displayed on the download page after the user has selected the profile name in the list.") . "</p>";
148
-            echo "<p>" . _("You can also tell us your RADIUS realm. ");
146
+            echo "<p>"._("First of all we need a name for the profile. This will be displayed to end users, so you may want to choose a descriptive name like 'Professors', 'Students of the Faculty of Bioscience', etc.")."</p>";
147
+            echo "<p>"._("Optionally, you can provide a longer descriptive text about who this profile is for. If you specify it, it will be displayed on the download page after the user has selected the profile name in the list.")."</p>";
148
+            echo "<p>"._("You can also tell us your RADIUS realm. ");
149 149
             if (\config\Master::FUNCTIONALITY_LOCATIONS['DIAGNOSTICS'] !== NULL) {
150 150
                 printf(_("This is useful if you want to use the sanity check module later, which tests reachability of your realm in the %s infrastructure. "), \config\ConfAssistant::CONSORTIUM['display_name']);
151 151
             }
152
-            echo _("It is required to enter the realm name if you want to support anonymous outer identities (see below).") . "</p>";
152
+            echo _("It is required to enter the realm name if you want to support anonymous outer identities (see below).")."</p>";
153 153
         }
154 154
 
155 155
         echo $optionDisplay->prefilledOptionTable("profile");
156 156
         ?>
157 157
         <button type='button' class='newoption' onclick='getXML("profile")'><?php echo _("Add new option"); ?></button>
158 158
         <table>
159
-            <caption><?php echo _("Basic Realm Information");?></caption>
159
+            <caption><?php echo _("Basic Realm Information"); ?></caption>
160 160
             <tr>
161
-                <th class="wai-invisible" scope="col"><?php echo _("Realm:");?></th>
162
-                <th class="wai-invisible" scope="col"><?php echo _("Realm input field");?></th>
161
+                <th class="wai-invisible" scope="col"><?php echo _("Realm:"); ?></th>
162
+                <th class="wai-invisible" scope="col"><?php echo _("Realm input field"); ?></th>
163 163
             </tr>
164 164
             <?php
165 165
             ?>
@@ -204,9 +204,9 @@  discard block
 block discarded – undo
204 204
 
205 205
         <?php
206 206
         if ($wizardStyle) {
207
-            echo "<p>" . sprintf(_("Some installers support a feature called 'Anonymous outer identity'. If you don't know what this is, please read <a href='%s'>this article</a>."), "https://confluence.terena.org/display/H2eduroam/eap-types") . "</p>";
208
-            echo "<p>" . _("On some platforms, the installers can suggest username endings and/or verify the user input to contain the realm suffix.") . "</p>";
209
-            echo "<p>" . _("The realm check feature needs to know an outer ID which actually gets a chance to authenticate. If your RADIUS server lets only select usernames pass, it is useful to supply the information which of those (outer ID) username we can use for testing.") . "</p>";
207
+            echo "<p>".sprintf(_("Some installers support a feature called 'Anonymous outer identity'. If you don't know what this is, please read <a href='%s'>this article</a>."), "https://confluence.terena.org/display/H2eduroam/eap-types")."</p>";
208
+            echo "<p>"._("On some platforms, the installers can suggest username endings and/or verify the user input to contain the realm suffix.")."</p>";
209
+            echo "<p>"._("The realm check feature needs to know an outer ID which actually gets a chance to authenticate. If your RADIUS server lets only select usernames pass, it is useful to supply the information which of those (outer ID) username we can use for testing.")."</p>";
210 210
         }
211 211
         ?>
212 212
         <p>
@@ -214,52 +214,52 @@  discard block
 block discarded – undo
214 214
 
215 215
             <!-- UI table to align elements-->
216 216
         <table>
217
-            <caption><?php echo _("Username Handling Options");?></caption>
217
+            <caption><?php echo _("Username Handling Options"); ?></caption>
218 218
             <tr>
219
-                <th class="wai-invisible" scope="col"><?php echo _("Option name");?></th>
220
-                <th class="wai-invisible" scope="col"><?php echo _("Option checkbox");?></th>
219
+                <th class="wai-invisible" scope="col"><?php echo _("Option name"); ?></th>
220
+                <th class="wai-invisible" scope="col"><?php echo _("Option checkbox"); ?></th>
221 221
             </tr>
222 222
             <tr>
223
-                <th colspan="2" style="text-align: left;"><?php echo _("Outer Identity Handling");?></th>
223
+                <th colspan="2" style="text-align: left;"><?php echo _("Outer Identity Handling"); ?></th>
224 224
             </tr>
225 225
             <tr>
226 226
                 <!-- checkbox and input field for anonymity support, available only when realm is known-->
227 227
                 <td>
228
-                    <span id='anon_support_label' style='<?php echo ($realm == "" ? "color:#999999" : "" ); ?>'>
228
+                    <span id='anon_support_label' style='<?php echo ($realm == "" ? "color:#999999" : ""); ?>'>
229 229
                         <?php echo _("Enable Anonymous Outer Identity:"); ?>
230 230
                     </span>
231 231
                 </td>
232 232
                 <td>
233
-                    <input type='checkbox' <?php echo ($useAnon != FALSE ? "checked" : "" ) . ($realm == "" ? " disabled" : "" ); ?> name='anon_support' onclick='
233
+                    <input type='checkbox' <?php echo ($useAnon != FALSE ? "checked" : "").($realm == "" ? " disabled" : ""); ?> name='anon_support' onclick='
234 234
                             if (this.form.elements["anon_support"].checked !== true) {
235 235
                                 this.form.elements["anon_local"].setAttribute("disabled", "disabled");
236 236
                             } else {
237 237
                                 this.form.elements["anon_local"].removeAttribute("disabled");
238 238
                             }
239 239
                             ;'/>
240
-                    <input type='text' <?php echo ($useAnon == FALSE ? "disabled" : "" ); ?> name='anon_local' value='<?php echo $anonLocal; ?>'/>
240
+                    <input type='text' <?php echo ($useAnon == FALSE ? "disabled" : ""); ?> name='anon_local' value='<?php echo $anonLocal; ?>'/>
241 241
                 </td>
242 242
             </tr>
243 243
             <tr>
244 244
                 <!-- checkbox and input field for check realm outer id, available only when realm is known-->
245 245
                 <td>
246
-                    <span id='checkuser_label' style='<?php echo ($realm == "" ? "color:#999999" : "" ); ?>'>
246
+                    <span id='checkuser_label' style='<?php echo ($realm == "" ? "color:#999999" : ""); ?>'>
247 247
                         <?php echo _("Use special Outer Identity for realm checks:"); ?>
248 248
                     </span>
249 249
                 </td>
250 250
                 <td>
251
-                    <input type='checkbox' <?php echo ($checkuserOuter != FALSE ? "checked" : "" ) . ($realm == "" ? " disabled" : "" ); ?> name='checkuser_support' onclick='
251
+                    <input type='checkbox' <?php echo ($checkuserOuter != FALSE ? "checked" : "").($realm == "" ? " disabled" : ""); ?> name='checkuser_support' onclick='
252 252
                             if (this.form.elements["checkuser_support"].checked !== true) {
253 253
                                 this.form.elements["checkuser_local"].setAttribute("disabled", "disabled");
254 254
                             } else {
255 255
                                 this.form.elements["checkuser_local"].removeAttribute("disabled");
256 256
                             }
257 257
                             ;'/>
258
-                    <input type='text' <?php echo ($checkuserOuter == FALSE ? "disabled" : "" ); ?> name='checkuser_local' value='<?php echo $checkuserValue; ?>'/>
258
+                    <input type='text' <?php echo ($checkuserOuter == FALSE ? "disabled" : ""); ?> name='checkuser_local' value='<?php echo $checkuserValue; ?>'/>
259 259
                 </td>
260 260
             </tr>
261 261
             <tr>
262
-                <th colspan="2" style="border-top: 2px solid; text-align: left;"><?php echo _("Inner Identity (Username) Handling");?></th>
262
+                <th colspan="2" style="border-top: 2px solid; text-align: left;"><?php echo _("Inner Identity (Username) Handling"); ?></th>
263 263
             </tr>
264 264
             <tr>
265 265
                 <!-- checkbox for "verify-->
@@ -270,7 +270,7 @@  discard block
 block discarded – undo
270 270
                 </td>
271 271
                 <td>
272 272
                     <input type='checkbox' <?php
273
-                    echo ($verify != FALSE ? "checked" : "" );
273
+                    echo ($verify != FALSE ? "checked" : "");
274 274
                     ?> name='verify_support' onclick='
275 275
                             if (this.form.elements["verify_support"].checked !== true || this.form.elements["realm"].value.length == 0) {
276 276
                                 this.form.elements["hint_support"].setAttribute("disabled", "disabled");
@@ -282,12 +282,12 @@  discard block
 block discarded – undo
282 282
             </tr>
283 283
             <tr>
284 284
                 <td>
285
-                    <span id='hint_label' style='<?php echo ($realm == "" ? "color:#999999" : "" ); ?>'>
285
+                    <span id='hint_label' style='<?php echo ($realm == "" ? "color:#999999" : ""); ?>'>
286 286
                         <?php echo _("Enforce exact realm in username"); ?>
287 287
                     </span>
288 288
                 </td>
289 289
                 <td>
290
-                    <input type='checkbox' <?php echo ($verify == FALSE ? "disabled" : "" ); ?> name='hint_support' <?php echo ( $hint != FALSE ? "checked" : "" ); ?> />
290
+                    <input type='checkbox' <?php echo ($verify == FALSE ? "disabled" : ""); ?> name='hint_support' <?php echo ($hint != FALSE ? "checked" : ""); ?> />
291 291
                 </td>
292 292
             </tr>
293 293
         </table>
@@ -297,20 +297,20 @@  discard block
 block discarded – undo
297 297
 
298 298
     <?php
299 299
     if ($wizardStyle) {
300
-        echo "<p>" . _("The CAT has a download area for end users. There, they will, for example, learn about the support pointers you entered earlier. The CAT can also immediately offer the installers for the profile for download. If you don't want that, you can instead enter a web site location where you want your users to be redirected to. You, as the administrator, can still download the profiles to place them on that page (see the 'Compatibility Matrix' button on the dashboard).") . "</p>";
300
+        echo "<p>"._("The CAT has a download area for end users. There, they will, for example, learn about the support pointers you entered earlier. The CAT can also immediately offer the installers for the profile for download. If you don't want that, you can instead enter a web site location where you want your users to be redirected to. You, as the administrator, can still download the profiles to place them on that page (see the 'Compatibility Matrix' button on the dashboard).")."</p>";
301 301
     }
302 302
     ?>
303 303
     <p>
304 304
 
305 305
         <?php
306
-        echo "<span id='redirect_label' style='" . ($realm == "" ? "color:#999999" : "" ) . "'><label for='redirect'>" . _("Redirect end users to own web page:") . "</label></span>
307
-                          <input type='checkbox'  name='redirect' id='redirect' " . ($blacklisted === FALSE ? "" : "checked " ) . "onclick='
306
+        echo "<span id='redirect_label' style='".($realm == "" ? "color:#999999" : "")."'><label for='redirect'>"._("Redirect end users to own web page:")."</label></span>
307
+                          <input type='checkbox'  name='redirect' id='redirect' " . ($blacklisted === FALSE ? "" : "checked ")."onclick='
308 308
                               if (this.form.elements[\"redirect\"].checked != true) {
309 309
                                 this.form.elements[\"redirect_target\"].setAttribute(\"disabled\", \"disabled\");
310 310
                               } else {
311 311
                                 this.form.elements[\"redirect_target\"].removeAttribute(\"disabled\");
312 312
                               };'/>
313
-                          <input type='text' name='redirect_target' " . ($blacklisted !== FALSE ? "value='$blacklisted'" : "disabled" ) . "/>";
313
+                          <input type='text' name='redirect_target' " . ($blacklisted !== FALSE ? "value='$blacklisted'" : "disabled")."/>";
314 314
         ?>
315 315
     </p>
316 316
 
@@ -319,7 +319,7 @@  discard block
 block discarded – undo
319 319
     <legend><strong><?php echo _("Supported EAP types"); ?></strong></legend>
320 320
     <?php
321 321
     if ($wizardStyle) {
322
-        echo "<p>" . _("Now, we need to know which EAP types your IdP supports. If you support multiple EAP types, you can assign every type a priority (1=highest). This tool will always generate an automatic installer for the EAP type with the highest priority; only if the user's device can't use that EAP type, we will use an EAP type further down in the list.") . "</p>";
322
+        echo "<p>"._("Now, we need to know which EAP types your IdP supports. If you support multiple EAP types, you can assign every type a priority (1=highest). This tool will always generate an automatic installer for the EAP type with the highest priority; only if the user's device can't use that EAP type, we will use an EAP type further down in the list.")."</p>";
323 323
     }
324 324
     ?>
325 325
     <?php
@@ -343,7 +343,7 @@  discard block
 block discarded – undo
343 343
     ?>
344 344
     <div>
345 345
         <table style="border:none">
346
-            <caption><?php echo _("EAP type support");?></caption>
346
+            <caption><?php echo _("EAP type support"); ?></caption>
347 347
             <tr>
348 348
                 <th scope="row" style="vertical-align:top; padding:1em">
349 349
                     <?php echo _('Supported EAP types for this profile'); ?>
@@ -353,7 +353,7 @@  discard block
 block discarded – undo
353 353
                         <?php
354 354
                         $D = [];
355 355
                         foreach ($prefill_methods as $prio => $value) {
356
-                            print '<li>' . $value->getPrintableRep() . "</li>\n";
356
+                            print '<li>'.$value->getPrintableRep()."</li>\n";
357 357
                             $D[$value->getPrintableRep()] = $prio;
358 358
                         }
359 359
                         ?>
@@ -379,7 +379,7 @@  discard block
 block discarded – undo
379 379
                             }
380 380
                             $display = $a->getPrintableRep();
381 381
                             if (!isset($D[$a->getPrintableRep()])) {
382
-                                print '<li class="eap1">' . $a->getPrintableRep() . "</li>\n";
382
+                                print '<li class="eap1">'.$a->getPrintableRep()."</li>\n";
383 383
                             }
384 384
                         }
385 385
                         ?>
@@ -392,8 +392,8 @@  discard block
 block discarded – undo
392 392
     foreach ($methods as $a) {
393 393
         $display = $a->getPrintableRep();
394 394
         $v = isset($D[$display]) ? $D[$display] : '';
395
-        print '<input type="hidden" class="eapm" name="' . $display . '" id="EAP-' . $display . '" value="' . $display . '">';
396
-        print '<input type="hidden" class="eapmv" name="' . $display . '-priority" id="EAP-' . $display . '-priority" value="' . $v . '">';
395
+        print '<input type="hidden" class="eapm" name="'.$display.'" id="EAP-'.$display.'" value="'.$display.'">';
396
+        print '<input type="hidden" class="eapmv" name="'.$display.'-priority" id="EAP-'.$display.'-priority" value="'.$v.'">';
397 397
     }
398 398
     ?>
399 399
     <br style="clear:both;" />
@@ -413,11 +413,11 @@  discard block
 block discarded – undo
413 413
 foreach ($optionsAlreadySet as $optionNames) {
414 414
     if (preg_match("/^support:/", $optionNames)) {
415 415
         $has_support_options[$optionNames] = "SET";
416
-        $support_text .= "<li><strong>" . $uiElements->displayName($optionNames) . "</strong></li>";
416
+        $support_text .= "<li><strong>".$uiElements->displayName($optionNames)."</strong></li>";
417 417
     }
418 418
     if (preg_match("/^media:/", $optionNames)) {
419 419
         $has_media_options[$optionNames] = "SET";
420
-        $media_text .= "<li><strong>" . $uiElements->displayName($optionNames) . "</strong></li>";
420
+        $media_text .= "<li><strong>".$uiElements->displayName($optionNames)."</strong></li>";
421 421
     }
422 422
 }
423 423
 $fields = [
@@ -426,22 +426,22 @@  discard block
 block discarded – undo
426 426
     "media" => _("Media Properties for this profile")];
427 427
 
428 428
 foreach ($fields as $name => $description) {
429
-    echo "<fieldset class='option_container' id='" . $name . "_override'>
429
+    echo "<fieldset class='option_container' id='".$name."_override'>
430 430
     <legend><strong>$description</strong></legend>
431 431
     <p>";
432 432
 
433
-    if (count(${"has_" . $name . "_options"}) > 0) {
434
-        printf(ngettext("The option %s is already defined IdP-wide. If you set it here on profile level, this setting will override the IdP-wide one.", "The options %s are already defined IdP-wide. If you set them here on profile level, these settings will override the IdP-wide ones.", count(${"has_" . $name . "_options"})), "<ul>" . ${$name . "_text"} . "</ul>");
433
+    if (count(${"has_".$name."_options"}) > 0) {
434
+        printf(ngettext("The option %s is already defined IdP-wide. If you set it here on profile level, this setting will override the IdP-wide one.", "The options %s are already defined IdP-wide. If you set them here on profile level, these settings will override the IdP-wide ones.", count(${"has_".$name."_options"})), "<ul>".${$name."_text"}."</ul>");
435 435
     }
436 436
 
437 437
     echo "</p>";
438 438
     echo $optionDisplay->prefilledOptionTable($name);
439
-    echo "<button type='button' class='newoption' onclick='getXML(\"$name\")'>" . _("Add new option") . "</button>";
439
+    echo "<button type='button' class='newoption' onclick='getXML(\"$name\")'>"._("Add new option")."</button>";
440 440
     echo "</fieldset>";
441 441
 }
442 442
 
443 443
 if ($wizardStyle) {
444
-    echo "<p>" . _("When you are sure that everything is correct, please click on 'Save data' and you will be taken to your IdP Dashboard page.") . "</p>";
444
+    echo "<p>"._("When you are sure that everything is correct, please click on 'Save data' and you will be taken to your IdP Dashboard page.")."</p>";
445 445
 }
446
-echo "<p><button type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_SAVE . "'>" . _("Save data") . "</button><button type='button' class='delete' name='abortbutton' value='abort' onclick='javascript:window.location = \"overview_idp.php?inst_id=$my_inst->identifier\"'>" . _("Discard changes") . "</button></p></form>";
446
+echo "<p><button type='submit' name='submitbutton' value='".web\lib\common\FormElements::BUTTON_SAVE."'>"._("Save data")."</button><button type='button' class='delete' name='abortbutton' value='abort' onclick='javascript:window.location = \"overview_idp.php?inst_id=$my_inst->identifier\"'>"._("Discard changes")."</button></p></form>";
447 447
 echo $deco->footer();
Please login to merge, or discard this patch.
web/admin/edit_profile_result.php 1 patch
Spacing   +27 added lines, -27 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
 $auth = new \web\lib\admin\Authentication();
25 25
 $deco = new \web\lib\admin\PageDecoration();
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
             echo $deco->pageheader(sprintf(_("%s: Edit Profile - Result"), \config\Master::APPEARANCE['productname']), "ADMIN-IDP");
53 53
         } else {
54 54
             $profile = $my_inst->newProfile(core\AbstractProfile::PROFILETYPE_RADIUS);
55
-            $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP " . $my_inst->identifier . " - Profile created");
55
+            $loggerInstance->writeAudit($_SESSION['user'], "NEW", "IdP ".$my_inst->identifier." - Profile created");
56 56
             echo $deco->pageheader(sprintf(_("%s: Profile wizard (step 3 completed)"), \config\Master::APPEARANCE['productname']), "ADMIN-IDP");
57 57
         }
58 58
         if (!$profile instanceof \core\ProfileRADIUS) {
@@ -109,16 +109,16 @@  discard block
 block discarded – undo
109 109
         ?>
110 110
         <h1><?php $tablecaption = _("Submitted attributes for this profile"); echo $tablecaption; ?></h1>
111 111
         <table>
112
-            <caption><?php echo $tablecaption;?></caption>
112
+            <caption><?php echo $tablecaption; ?></caption>
113 113
             <tr>
114
-                <th class="wai-invisible" scope="col"><?php echo _("Overall Result");?></th>
115
-                <th class="wai-invisible" scope="col"><?php echo _("Details");?></th>
114
+                <th class="wai-invisible" scope="col"><?php echo _("Overall Result"); ?></th>
115
+                <th class="wai-invisible" scope="col"><?php echo _("Details"); ?></th>
116 116
             </tr>
117 117
             <?php
118 118
             $uiElements = new web\lib\admin\UIElements();
119 119
             // set realm info, if submitted
120 120
             if ($realm !== FALSE) {
121
-                $profile->setRealm($anonLocal . "@" . $realm);
121
+                $profile->setRealm($anonLocal."@".$realm);
122 122
                 echo $uiElements->boxOkay(sprintf(_("Realm: <strong>%s</strong>"), $realm));
123 123
             } else {
124 124
                 $profile->setRealm("");
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
                     echo $uiElements->boxError(_("Realm check username cannot be configured: realm is missing!"));
145 145
                 } else {
146 146
                     $profile->setRealmcheckUser(true, $checkuser_name);
147
-                    echo $uiElements->boxOkay(sprintf(_("Special username for realm check is <strong>%s</strong>, the value is <strong>%s</strong>"), _("ON"), $checkuser_name . "@" . $realm));
147
+                    echo $uiElements->boxOkay(sprintf(_("Special username for realm check is <strong>%s</strong>, the value is <strong>%s</strong>"), _("ON"), $checkuser_name."@".$realm));
148 148
                 }
149 149
             } else {
150 150
                 $profile->setRealmCheckUser(false);
@@ -156,12 +156,12 @@  discard block
 block discarded – undo
156 156
                 $extratext = "";
157 157
                 if (!empty($realm)) {
158 158
                     if ($hint !== FALSE) {
159
-                        $extratext = " " . sprintf(_("The realm portion MUST be exactly '...@%s'."), $realm);
159
+                        $extratext = " ".sprintf(_("The realm portion MUST be exactly '...@%s'."), $realm);
160 160
                     } else {
161
-                        $extratext = " " . sprintf(_("The realm portion MUST end with '%s' but sub-realms of it are allowed (i.e. 'user@%s' and 'user@<...>.%s' are both acceptable)."), $realm, $realm, $realm);
161
+                        $extratext = " ".sprintf(_("The realm portion MUST end with '%s' but sub-realms of it are allowed (i.e. 'user@%s' and 'user@<...>.%s' are both acceptable)."), $realm, $realm, $realm);
162 162
                     }
163 163
                 }
164
-                echo $uiElements->boxOkay(_("Where possible, supplicants will verify that username inputs contain a syntactically correct realm.") . $extratext);
164
+                echo $uiElements->boxOkay(_("Where possible, supplicants will verify that username inputs contain a syntactically correct realm.").$extratext);
165 165
             } else {
166 166
                 $profile->setInputVerificationPreference(false, false);
167 167
             }
@@ -193,30 +193,30 @@  discard block
 block discarded – undo
193 193
                 echo $uiElements->boxOkay(_("Redirection is <strong>OFF</strong>"));
194 194
             }
195 195
 
196
-            $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile " . $profile->identifier . " - attributes changed");
196
+            $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile ".$profile->identifier." - attributes changed");
197 197
             // reload the profile to ingest new CA and server names if any; before checking EAP completeness
198 198
             $reloadedProfileNr1 = \core\ProfileFactory::instantiate($profile->identifier);
199 199
             foreach (\core\common\EAP::listKnownEAPTypes() as $a) {
200 200
                 if ($a->getIntegerRep() == \core\common\EAP::INTEGER_SILVERBULLET) { // do not allow adding silverbullet via the backdoor
201 201
                     continue;
202 202
                 }
203
-                if (isset($_POST[$a->getPrintableRep()]) && isset($_POST[$a->getPrintableRep() . "-priority"]) && is_numeric($_POST[$a->getPrintableRep() . "-priority"])) {
204
-                    $priority = (int) $_POST[$a->getPrintableRep() . "-priority"];
203
+                if (isset($_POST[$a->getPrintableRep()]) && isset($_POST[$a->getPrintableRep()."-priority"]) && is_numeric($_POST[$a->getPrintableRep()."-priority"])) {
204
+                    $priority = (int) $_POST[$a->getPrintableRep()."-priority"];
205 205
                     // add EAP type to profile as requested, but ...
206 206
                     $reloadedProfileNr1->addSupportedEapMethod($a, $priority);
207
-                    $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile " . $reloadedProfileNr1->identifier . " - supported EAP types changed");
207
+                    $loggerInstance->writeAudit($_SESSION['user'], "MOD", "Profile ".$reloadedProfileNr1->identifier." - supported EAP types changed");
208 208
                     // see if we can enable the EAP type, or if info is missing
209 209
                     $eapcompleteness = $reloadedProfileNr1->isEapTypeDefinitionComplete($a);
210 210
                     if ($eapcompleteness === true) {
211
-                        echo $uiElements->boxOkay(_("Supported EAP Type: ") . "<strong>" . $a->getPrintableRep() . "</strong>");
211
+                        echo $uiElements->boxOkay(_("Supported EAP Type: ")."<strong>".$a->getPrintableRep()."</strong>");
212 212
                     } else {
213 213
                         $warntext = "";
214 214
                         if (is_array($eapcompleteness)) {
215 215
                             foreach ($eapcompleteness as $item) {
216
-                                $warntext .= "<strong>" . $uiElements->displayName($item) . "</strong> ";
216
+                                $warntext .= "<strong>".$uiElements->displayName($item)."</strong> ";
217 217
                             }
218 218
                         }
219
-                        echo $uiElements->boxWarning(sprintf(_("Supported EAP Type: <strong>%s</strong> is missing required information %s !"), $a->getPrintableRep(), $warntext) . "<br/>" . _("The EAP type was added to the profile, but you need to complete the missing information before we can produce installers for you."));
219
+                        echo $uiElements->boxWarning(sprintf(_("Supported EAP Type: <strong>%s</strong> is missing required information %s !"), $a->getPrintableRep(), $warntext)."<br/>"._("The EAP type was added to the profile, but you need to complete the missing information before we can produce installers for you."));
220 220
                     }
221 221
                 }
222 222
             }
@@ -227,23 +227,23 @@  discard block
 block discarded – undo
227 227
             if (count($significantChanges) > 0) {
228 228
                 $myInstOriginal = new \core\IdP($profile->institution);
229 229
                 // send a notification/alert mail to someone we know is in charge
230
-                $text = _("To whom it may concern,") . "\n\n";
230
+                $text = _("To whom it may concern,")."\n\n";
231 231
                 /// were made to the *Identity Provider* *LU* / integer number of IdP / (previously known as) Name
232
-                $text .= sprintf(_("significant changes were made to a RADIUS deployment profile of the %s %s / %s / '%s'."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name) . "\n\n";
232
+                $text .= sprintf(_("significant changes were made to a RADIUS deployment profile of the %s %s / %s / '%s'."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name)."\n\n";
233 233
                 if (isset($significantChanges[\core\AbstractProfile::CA_CLASH_ADDED])) {
234
-                    $text .= _("WARNING! A new trusted root CA was added, and it has the exact same name as a previously existing root CA. This may (but does not necessarily) mean that this is an attempt to insert an unauthorised trust root by disguising as the genuine one. The details are below:") . "\n\n";
235
-                    $text .= $significantChanges[\core\AbstractProfile::CA_CLASH_ADDED] . "\n\n";
234
+                    $text .= _("WARNING! A new trusted root CA was added, and it has the exact same name as a previously existing root CA. This may (but does not necessarily) mean that this is an attempt to insert an unauthorised trust root by disguising as the genuine one. The details are below:")."\n\n";
235
+                    $text .= $significantChanges[\core\AbstractProfile::CA_CLASH_ADDED]."\n\n";
236 236
                 }
237 237
                 if (isset($significantChanges[\core\AbstractProfile::CA_ADDED])) {
238 238
                     $text .= _("A new trusted root CA was added. The details are below:")."\n\n";
239
-                    $text .= $significantChanges[\core\AbstractProfile::CA_ADDED] . "\n\n";
239
+                    $text .= $significantChanges[\core\AbstractProfile::CA_ADDED]."\n\n";
240 240
                 }
241 241
                 if (isset($significantChanges[\core\AbstractProfile::SERVERNAME_ADDED])) {
242
-                    $text .= _("A new acceptable server name for the authentication server was added. The details are below:") . "\n\n";
243
-                    $text .= $significantChanges[\core\AbstractProfile::SERVERNAME_ADDED] . "\n\n";
242
+                    $text .= _("A new acceptable server name for the authentication server was added. The details are below:")."\n\n";
243
+                    $text .= $significantChanges[\core\AbstractProfile::SERVERNAME_ADDED]."\n\n";
244 244
                 }
245
-                $text .= _("This mail is merely a cross-check because these changes can be security-relevant. If the change was expected, you do not need to take any action.") . "\n\n";
246
-                $text .= _("Greetings, ") . "\n\n" . \config\Master::APPEARANCE['productname_long'];
245
+                $text .= _("This mail is merely a cross-check because these changes can be security-relevant. If the change was expected, you do not need to take any action.")."\n\n";
246
+                $text .= _("Greetings, ")."\n\n".\config\Master::APPEARANCE['productname_long'];
247 247
                 // (currently, send hard-wired to NRO - future: for linked insts, check eduroam DBv2 and send to registered admins directly)
248 248
                 $fed = new core\Federation($myInstOriginal->federation);
249 249
                 foreach ($fed->listFederationAdmins() as $id) {
@@ -261,7 +261,7 @@  discard block
 block discarded – undo
261 261
         <?php
262 262
         if (count($reloadedProfileNr2->getEapMethodsinOrderOfPreference(1)) > 0) {
263 263
             echo "<form method='post' action='overview_installers.php?inst_id=$my_inst->identifier&profile_id=$reloadedProfileNr2->identifier' accept-charset='UTF-8'>
264
-        <button type='submit'>" . _("Continue to Installer Fine-Tuning and Download") . "</button>
264
+        <button type='submit'>"._("Continue to Installer Fine-Tuning and Download")."</button>
265 265
     </form>";
266 266
         }
267 267
         echo $deco->footer();
Please login to merge, or discard this patch.
web/skins/modern/Divs.php 1 patch
Spacing   +34 added lines, -34 removed lines patch added patch discarded remove patch
@@ -60,11 +60,11 @@  discard block
 block discarded – undo
60 60
         $location = $this->Gui->skinObject->findResourceUrl("IMAGES", "consortium_logo.png");
61 61
         if ($location !== FALSE) {
62 62
             $retval .= "<div id='cat_logo'>
63
-            <a href='" . \config\ConfAssistant::CONSORTIUM['homepage'] . "'><img id='logo_img' src='$location' alt='Consortium Logo'/></a>
63
+            <a href='" . \config\ConfAssistant::CONSORTIUM['homepage']."'><img id='logo_img' src='$location' alt='Consortium Logo'/></a>
64 64
             <span>Configuration Assistant Tool</span>
65 65
             </div>";
66 66
         }
67
-        $retval .= "<div id='motd'>" . (isset(\config\Master::APPEARANCE['MOTD']) ? \config\Master::APPEARANCE['MOTD'] : '&nbsp') . "</div>";
67
+        $retval .= "<div id='motd'>".(isset(\config\Master::APPEARANCE['MOTD']) ? \config\Master::APPEARANCE['MOTD'] : '&nbsp')."</div>";
68 68
         $loc2 = $this->Gui->skinObject->findResourceUrl("IMAGES", "icons/menu.png");
69 69
         if ($loc2 !== FALSE) {
70 70
             $retval .= "<img id='hamburger' src='$loc2' alt='Menu'/>";
@@ -87,13 +87,13 @@  discard block
 block discarded – undo
87 87
     public function divUserWelcome() {
88 88
         $retval = "
89 89
 <div id='user_welcome'> <!-- this information is shown just before the download -->
90
-    <strong>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_PAGEHEADING] . "</strong>
90
+    <strong>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_PAGEHEADING]."</strong>
91 91
     <p>
92 92
     <span id='download_info'>
93 93
     <!-- the empty href is dynamically exchanged with the actual path by jQuery at runtime -->
94
-        " . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_DOWNLOAD] . "
94
+        " . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_DOWNLOAD]."
95 95
     </span>
96
-    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_HEADING] . "
96
+    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_HEADING]."
97 97
     <br/>
98 98
     <br/>";
99 99
         switch (\config\ConfAssistant::CONSORTIUM['name']) {
@@ -104,12 +104,12 @@  discard block
 block discarded – undo
104 104
         }
105 105
         $retval .= "
106 106
     </p>
107
-    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_USAGE] . "
108
-    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_PROBLEMS] . "
109
-    <p>" . (false ? $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_TERMS] : "") . "
107
+    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_USAGE]."
108
+    <p>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_PROBLEMS]."
109
+    <p>" . (false ? $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_TERMS] : "")."
110 110
     </p>
111 111
     <p>
112
-    <a href='javascript:back_to_downloads()'><strong>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_BACKTODOWNLOADS] . "</strong></a>
112
+    <a href='javascript:back_to_downloads()'><strong>" . $this->Gui->textTemplates->templates[user\WELCOME_ABOARD_BACKTODOWNLOADS]."</strong></a>
113 113
     </p>
114 114
 </div> <!-- id='user_welcomer_page' -->
115 115
 ";
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
     public function divSilverbullet() {
125 125
         $retval = "
126 126
 <div id='silverbullet'>"
127
-                . $this->Gui->textTemplates->templates[user\SB_GO_AWAY] .
127
+                . $this->Gui->textTemplates->templates[user\SB_GO_AWAY].
128 128
                 "</div>
129 129
     ";
130 130
         return $retval;
@@ -138,14 +138,14 @@  discard block
 block discarded – undo
138 138
     public function divTopWelcome() {
139 139
         $retval = '';
140 140
         if (\config\ConfAssistant::CONSORTIUM['name'] == "eduroam" && isset(\config\ConfAssistant::CONSORTIUM['deployment-voodoo']) && \config\ConfAssistant::CONSORTIUM['deployment-voodoo'] == "Operations Team") { // SW: APPROVED
141
-            $retval = "<br><div id='top_invite_ad'>" . $this->Gui->textTemplates->templates[user\FRONTPAGE_EDUROAM_AD] . "</div>";
141
+            $retval = "<br><div id='top_invite_ad'>".$this->Gui->textTemplates->templates[user\FRONTPAGE_EDUROAM_AD]."</div>";
142 142
         }
143 143
         return "
144 144
 <div id='welcome_top1'>
145
-    " . $this->Gui->textTemplates->templates[user\HEADING_TOPLEVEL_GREET] . "
145
+    " . $this->Gui->textTemplates->templates[user\HEADING_TOPLEVEL_GREET]."
146 146
 </div>
147 147
 <div id='top_invite'>
148
-    " . $this->Gui->textTemplates->templates[user\HEADING_TOPLEVEL_PURPOSE] . $retval . "
148
+    " . $this->Gui->textTemplates->templates[user\HEADING_TOPLEVEL_PURPOSE].$retval."
149 149
 </div>";
150 150
     }
151 151
 
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
         $retval = "
159 159
 <div id='roller'>
160 160
     <div id='slides'>
161
-        <span id='line1'>" . $this->Gui->textTemplates->templates[user\FRONTPAGE_ROLLER_EASY] . "</span>
161
+        <span id='line1'>" . $this->Gui->textTemplates->templates[user\FRONTPAGE_ROLLER_EASY]."</span>
162 162
         <span id='line2'></span>
163 163
         <span id='line3'></span>
164 164
         <span id='line4'>";
@@ -220,9 +220,9 @@  discard block
 block discarded – undo
220 220
     public function divProfiles() {
221 221
         return "
222 222
 <div id='profiles'> <!-- this is the profile selection filled during run time -->
223
-    <div id='profiles_h' class='sub_h'>" . $this->Gui->textTemplates->templates[user\PROFILE_SELECTION] . "
223
+    <div id='profiles_h' class='sub_h'>" . $this->Gui->textTemplates->templates[user\PROFILE_SELECTION]."
224 224
     </div>" .
225
-                "<select id='profile_list'></select><div id='profile_desc' class='profile_desc'></div>" .
225
+                "<select id='profile_list'></select><div id='profile_desc' class='profile_desc'></div>".
226 226
                 "</div>";
227 227
     }
228 228
 
@@ -250,7 +250,7 @@  discard block
 block discarded – undo
250 250
     public function divInstitution($selectButton = TRUE) {
251 251
         $retval = "<div id='institution_name'>
252 252
     <span id='inst_name_span'></span> <div id='inst_extra_text'></div><!-- this will be filled with the IdP name -->" .
253
-                ($selectButton ? "<a  id='select_another' class='signin' href=\"\">" . $this->Gui->textTemplates->templates[user\INSTITUTION_SELECTION] . "</a>" : "") .
253
+                ($selectButton ? "<a  id='select_another' class='signin' href=\"\">".$this->Gui->textTemplates->templates[user\INSTITUTION_SELECTION]."</a>" : "").
254 254
                 "</div>";
255 255
         $retval .= $this->emptyImage('idp_logo', 'IdP Logo');
256 256
         return $retval;
@@ -274,7 +274,7 @@  discard block
 block discarded – undo
274 274
     public function divOtherinstallers() {
275 275
         $retval = "
276 276
 <div class='sub_h'>
277
-    <div id='other_installers'>" . $this->Gui->textTemplates->templates[user\DOWNLOAD_CHOOSE] . "
277
+    <div id='other_installers'>" . $this->Gui->textTemplates->templates[user\DOWNLOAD_CHOOSE]."
278 278
          <table id='device_list' style='padding:0px;'>";
279 279
 
280 280
         foreach ($this->Gui->listDevices(isset($_REQUEST['hidden']) ? $_REQUEST['hidden'] : 0) as $group => $deviceGroup) {
@@ -282,18 +282,18 @@  discard block
 block discarded – undo
282 282
             $deviceIndex = 0;
283 283
 
284 284
             $imgTag = "";
285
-            $imgLocation = $this->Gui->skinObject->findResourceUrl("IMAGES", "vendorlogo/" . $group . ".png");
285
+            $imgLocation = $this->Gui->skinObject->findResourceUrl("IMAGES", "vendorlogo/".$group.".png");
286 286
             if ($imgLocation !== FALSE) {
287
-                $imgTag = '<img src="' . $imgLocation . '" alt="' . $group . ' Device" title="' . $group . ' Device">';
287
+                $imgTag = '<img src="'.$imgLocation.'" alt="'.$group.' Device" title="'.$group.' Device">';
288 288
             }
289
-            $retval .= '<tbody><tr><td class="vendor" rowspan="' . $groupIndex . '">' . $imgTag . '</td>';
289
+            $retval .= '<tbody><tr><td class="vendor" rowspan="'.$groupIndex.'">'.$imgTag.'</td>';
290 290
             foreach ($deviceGroup as $d => $D) {
291 291
                 if ($deviceIndex) {
292 292
                     $retval .= '<tr>';
293 293
                 }
294
-                $retval .= "<td><button id='" . $d . "'>" . $D['display'] . "</button>"
295
-                        . "<div class='device_info' id='info_" . $d . "'></div></td>"
296
-                        . "<td><button class='more_info_b' id='info_b_" . $d . "'>i</button></td></tr>\n";
294
+                $retval .= "<td><button id='".$d."'>".$D['display']."</button>"
295
+                        . "<div class='device_info' id='info_".$d."'></div></td>"
296
+                        . "<td><button class='more_info_b' id='info_b_".$d."'>i</button></td></tr>\n";
297 297
                 $deviceIndex++;
298 298
             }
299 299
             $retval .= "</tbody>";
@@ -313,15 +313,15 @@  discard block
 block discarded – undo
313 313
      * @return string
314 314
      */
315 315
     public function divGuessOs($operatingSystem) {
316
-        $vendorlogo = $this->Gui->skinObject->findResourceUrl("IMAGES", "vendorlogo/" . $operatingSystem['group'] . ".png");
316
+        $vendorlogo = $this->Gui->skinObject->findResourceUrl("IMAGES", "vendorlogo/".$operatingSystem['group'].".png");
317 317
         $vendorstyle = "";
318 318
         if ($vendorlogo !== FALSE) {
319
-            $vendorstyle = "style='background-image:url(\"" . $vendorlogo . "\")'";
319
+            $vendorstyle = "style='background-image:url(\"".$vendorlogo."\")'";
320 320
         }
321 321
         $deleteIcon = $this->Gui->skinObject->findResourceUrl("IMAGES", "icons/delete_32.png");
322 322
         $deleteImg = "";
323 323
         if ($deleteIcon !== FALSE) {
324
-            $deleteImg = "<img id='cross_icon_" . $operatingSystem['device'] . "' src='$deleteIcon' >";
324
+            $deleteImg = "<img id='cross_icon_".$operatingSystem['device']."' src='$deleteIcon' >";
325 325
         }
326 326
         return "
327 327
 <div class='sub_h' id='guess_os'>
@@ -329,23 +329,23 @@  discard block
 block discarded – undo
329 329
     <table id='browser'>
330 330
         <tr>
331 331
             <td>
332
-                <button class='large_button guess_os' $vendorstyle id='g_" . $operatingSystem['device'] . "'>
332
+                <button class='large_button guess_os' $vendorstyle id='g_".$operatingSystem['device']."'>
333 333
                     $deleteImg
334
-                    <div class='download_button_text_1' id='download_button_header_" . $operatingSystem['device'] . "'> " . $this->Gui->textTemplates->templates[user\DOWNLOAD_MESSAGE] . "
334
+                    <div class='download_button_text_1' id='download_button_header_".$operatingSystem['device']."'> ".$this->Gui->textTemplates->templates[user\DOWNLOAD_MESSAGE]."
335 335
                     </div>
336 336
                     <div class='download_button_text'>" .
337
-                $operatingSystem['display'] . "
337
+                $operatingSystem['display']."
338 338
                     </div>
339 339
                 </button>
340
-                <div class='device_info' id='info_g_" . $operatingSystem['device'] . "'></div>
340
+                <div class='device_info' id='info_g_" . $operatingSystem['device']."'></div>
341 341
           </td>
342 342
           <td style='vertical-align:top'>
343
-               <button class='more_info_b large_button' id='g_info_b_" . $operatingSystem['device'] . "'>i</button>
343
+               <button class='more_info_b large_button' id='g_info_b_" . $operatingSystem['device']."'>i</button>
344 344
           </td>
345 345
       </tr>
346 346
     </table> <!-- id='browser' -->
347 347
     <div class='sub_h'>
348
-       <a href='javascript:other_installers()'>" . $this->Gui->textTemplates->templates[user\DOWNLOAD_CHOOSE] . "</a>
348
+       <a href='javascript:other_installers()'>" . $this->Gui->textTemplates->templates[user\DOWNLOAD_CHOOSE]."</a>
349 349
     </div>
350 350
 </div> <!-- id='guess_os' -->";
351 351
     }
@@ -366,7 +366,7 @@  discard block
 block discarded – undo
366 366
             </td>";
367 367
 
368 368
         if (!empty(\config\Master::APPEARANCE['privacy_notice_url'])) {
369
-            $retval .= "<td><a href='" . \config\Master::APPEARANCE['privacy_notice_url'] . "'>" . sprintf(_("%s Privacy Notice"), \config\ConfAssistant::CONSORTIUM['display_name']) . "</a></td>";
369
+            $retval .= "<td><a href='".\config\Master::APPEARANCE['privacy_notice_url']."'>".sprintf(_("%s Privacy Notice"), \config\ConfAssistant::CONSORTIUM['display_name'])."</a></td>";
370 370
         }
371 371
         $retval .= "<td>";
372 372
         if (\config\ConfAssistant::CONSORTIUM['name'] == "eduroam" && isset(\config\ConfAssistant::CONSORTIUM['deployment-voodoo']) && \config\ConfAssistant::CONSORTIUM['deployment-voodoo'] == "Operations Team") {
Please login to merge, or discard this patch.
web/skins/modern/user/js/cat_js.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@  discard block
 block discarded – undo
20 20
  */
21 21
 
22 22
 $cat = new \web\lib\user\Gui();
23
-$idpId = filter_input(INPUT_GET, 'idp', FILTER_VALIDATE_INT) ?? filter_input(INPUT_POST, 'idp', FILTER_VALIDATE_INT)?? 0;
23
+$idpId = filter_input(INPUT_GET, 'idp', FILTER_VALIDATE_INT) ?? filter_input(INPUT_POST, 'idp', FILTER_VALIDATE_INT) ?? 0;
24 24
 $profileId = filter_input(INPUT_GET, 'profile', FILTER_VALIDATE_INT) ?? filter_input(INPUT_POST, 'profile', FILTER_VALIDATE_INT) ?? 0;
25 25
 $skinObject = $Gui->skinObject;
26 26
 if (\config\ConfAssistant::PRELOAD_IDPS) {
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
         otherdata = j.otherdata;
122 122
     if(! result) {
123 123
       alert("<?php $cat->javaScriptEscapedEcho(_("no matching data found"))?>");
124
-      document.location.href='<?php echo rtrim(dirname($_SERVER['SCRIPT_NAME']), '/') . '/' ?>';
124
+      document.location.href='<?php echo rtrim(dirname($_SERVER['SCRIPT_NAME']), '/').'/' ?>';
125 125
     }
126 126
     j = j.data;
127 127
     n = j.length;
@@ -258,7 +258,7 @@  discard block
 block discarded – undo
258 258
        result = j1.status;
259 259
        if(! result) {
260 260
             alert("<?php $cat->javaScriptEscapedEcho(_("no matching data found")) ?>");
261
-            document.location.href='<?php echo rtrim(dirname($_SERVER['SCRIPT_NAME']), '/') . '/' ?>';
261
+            document.location.href='<?php echo rtrim(dirname($_SERVER['SCRIPT_NAME']), '/').'/' ?>';
262 262
        }
263 263
        j = j1.data;
264 264
        if(j.description !== undefined && j.description) {
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
          $("#profile_desc").hide();
270 270
          $("#profile_desc").text('');
271 271
        }
272
-       updateTxt = '<span class="user_info"><?php $cat->javaScriptEscapedEcho(_("This entry was last updated at:"));?>'+' '+j.last_changed+'</span><br/>';
272
+       updateTxt = '<span class="user_info"><?php $cat->javaScriptEscapedEcho(_("This entry was last updated at:")); ?>'+' '+j.last_changed+'</span><br/>';
273 273
        if(j.local_url !== undefined && j.local_url) 
274 274
        txt = txt+'<span class="user_info"><?php $cat->javaScriptEscapedEcho(_("WWW:")); ?> <a href="'+j.local_url+'" target="_blank">'+j.local_url+'</a></span><br/>';
275 275
        if(j.local_email !== undefined && j.local_email) 
Please login to merge, or discard this patch.