Test Setup Failed
Push — master ( 0d3421...3409d2 )
by Stefan
06:37
created
web/admin/edit_hotspot.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
  */
27 27
 ?>
28 28
 <?php
29
-require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php";
29
+require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php";
30 30
 
31 31
 $deco = new \web\lib\admin\PageDecoration();
32 32
 $validator = new \web\lib\common\InputValidation();
@@ -36,12 +36,12 @@  discard block
 block discarded – undo
36 36
 $myfed = new \core\Federation($my_inst->federation);
37 37
 
38 38
 if (!isset($_GET['deployment_id'])) {
39
-    if (isset($_POST['consortium']) && ( $_POST['consortium'] == "eduroam" ||
40
-            ( $_POST['consortium'] == "OpenRoaming" && count($myfed->getAttributes("fed:openroaming")) > 0 )
39
+    if (isset($_POST['consortium']) && ($_POST['consortium'] == "eduroam" ||
40
+            ($_POST['consortium'] == "OpenRoaming" && count($myfed->getAttributes("fed:openroaming")) > 0)
41 41
             )
42 42
     ) {
43 43
         $my_inst->newDeployment(\core\AbstractDeployment::DEPLOYMENTTYPE_MANAGED, $_POST['consortium']);
44
-        header("Location: overview_org.php?inst_id=" . $my_inst->identifier);
44
+        header("Location: overview_org.php?inst_id=".$my_inst->identifier);
45 45
         exit(0);
46 46
     } else {
47 47
         throw new Exception("Desired consortium for Managed SP needs to be specified, and allowed!");
@@ -98,14 +98,14 @@  discard block
 block discarded – undo
98 98
                 if (isset($_POST['agreement']) && $_POST['agreement'] == "true") {
99 99
                     $deployment->addAttribute("hiddenmanagedsp:tou_accepted", NULL, 1);
100 100
                 }
101
-                header("Location: overview_org.php?inst_id=" . $my_inst->identifier);
101
+                header("Location: overview_org.php?inst_id=".$my_inst->identifier);
102 102
                 exit(0);
103 103
             case web\lib\common\FormElements::BUTTON_DELETE:
104 104
                 $response = $deployment->setRADIUSconfig();
105 105
                 if (in_array('OK', $response)) {
106 106
                     $deployment->deactivate();
107 107
                 }
108
-                header("Location: overview_org.php?inst_id=" . $my_inst->identifier . '&' . urldecode(http_build_query($response)));
108
+                header("Location: overview_org.php?inst_id=".$my_inst->identifier.'&'.urldecode(http_build_query($response)));
109 109
                 exit(0);
110 110
             case web\lib\common\FormElements::BUTTON_ACTIVATE:
111 111
                 if (count($deployment->getAttributes("hiddenmanagedsp:tou_accepted")) > 0) {
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
                     if (in_array('OK', $response)) {
114 114
                         $deployment->activate();
115 115
                     }
116
-                    header("Location: overview_org.php?inst_id=" . $my_inst->identifier . '&' . urldecode(http_build_query($response)));
116
+                    header("Location: overview_org.php?inst_id=".$my_inst->identifier.'&'.urldecode(http_build_query($response)));
117 117
                     exit(0);
118 118
                 } else {
119 119
                     throw new Exception("Activate button pushed without acknowledged ToUs!");
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
                 } else {
139 139
                     $response = ['NOOP', 'NOOP'];
140 140
                 }
141
-                header("Location: overview_org.php?inst_id=" . $my_inst->identifier . '&' . urldecode(http_build_query($response)));
141
+                header("Location: overview_org.php?inst_id=".$my_inst->identifier.'&'.urldecode(http_build_query($response)));
142 142
                 exit(0);
143 143
             default:
144 144
                 throw new Exception("Unknown button actioon requested!");
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
     echo $uiElements->instLevelInfoBoxes($my_inst);
168 168
     $deploymentOptions = $deployment->getAttributes();
169 169
     echo "<form enctype='multipart/form-data' action='edit_hotspot.php?inst_id=$my_inst->identifier&amp;deployment_id=$deployment->identifier' method='post' accept-charset='UTF-8'>
170
-                <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Master::MAX_UPLOAD_SIZE . "'>";
170
+                <input type='hidden' name='MAX_FILE_SIZE' value='".\config\Master::MAX_UPLOAD_SIZE."'>";
171 171
     $optionDisplay = new \web\lib\admin\OptionDisplay($deploymentOptions, \core\Options::LEVEL_PROFILE);
172 172
     ?>
173 173
     <fieldset class='option_container' id='managedsp_override'>
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
                 <!-- input for VLAN identifier for home users-->
202 202
                 <td>
203 203
                     <span id='vlan_label'>
204
-                        <?php echo sprintf(_("VLAN tag for own users%s:"), ($vlan === NULL ? "" : " " . _("(unset with '0')"))); ?>
204
+                        <?php echo sprintf(_("VLAN tag for own users%s:"), ($vlan === NULL ? "" : " "._("(unset with '0')"))); ?>
205 205
                     </span>
206 206
                 </td>
207 207
                 <td>
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
     </fieldset>
222 222
 
223 223
     <?php
224
-    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_org.php?inst_id=$my_inst->identifier\"'>" . _("Discard changes") . "</button></p></form>";
224
+    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_org.php?inst_id=$my_inst->identifier\"'>"._("Discard changes")."</button></p></form>";
225 225
     echo $deco->footer();
226 226
 
227 227
     
228 228
\ No newline at end of file
Please login to merge, or discard this patch.