@@ -19,7 +19,7 @@ discard block |
||
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 | 'CatBaseUrl', |
@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | |
43 | 43 | $uiElements = new \web\lib\admin\UIElements(); |
44 | 44 | |
45 | -if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || \config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL" ) { |
|
45 | +if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL" || \config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL") { |
|
46 | 46 | $Tests[] = 'Makensis'; |
47 | 47 | $Tests[] = 'Makensis=>NSISmodules'; |
48 | 48 | } |
@@ -26,7 +26,7 @@ discard block |
||
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 | $auth = new \web\lib\admin\Authentication(); |
32 | 32 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -61,13 +61,13 @@ discard block |
||
61 | 61 | ?> |
62 | 62 | </h1> |
63 | 63 | <div class='infobox'> |
64 | - <h2><?php $tablecaption = sprintf(_("%s Properties"),$uiElements->nomenclatureFed); echo $tablecaption?></h2> |
|
64 | + <h2><?php $tablecaption = sprintf(_("%s Properties"), $uiElements->nomenclatureFed); echo $tablecaption?></h2> |
|
65 | 65 | <table> |
66 | - <caption><?php echo $tablecaption;?></caption> |
|
66 | + <caption><?php echo $tablecaption; ?></caption> |
|
67 | 67 | <tr> |
68 | - <th class="wai-invisible" scope="col"><?php echo _("Property Type");?></th> |
|
69 | - <th class="wai-invisible" scope="col"><?php echo _("Language if applicable");?></th> |
|
70 | - <th class="wai-invisible" scope="col"><?php echo _("Property Value");?></th> |
|
68 | + <th class="wai-invisible" scope="col"><?php echo _("Property Type"); ?></th> |
|
69 | + <th class="wai-invisible" scope="col"><?php echo _("Language if applicable"); ?></th> |
|
70 | + <th class="wai-invisible" scope="col"><?php echo _("Property Value"); ?></th> |
|
71 | 71 | </tr> |
72 | 72 | <tr> |
73 | 73 | <td><?php echo _("Country:"); ?></td> |
@@ -78,11 +78,11 @@ discard block |
||
78 | 78 | </table> |
79 | 79 | </div> |
80 | 80 | <?php |
81 | - echo "<form enctype='multipart/form-data' action='edit_federation_result.php?fed_id=$my_fed->tld" . "' method='post' accept-charset='UTF-8'> |
|
82 | - <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Main::MAX_UPLOAD_SIZE . "'>"; |
|
81 | + echo "<form enctype='multipart/form-data' action='edit_federation_result.php?fed_id=$my_fed->tld"."' method='post' accept-charset='UTF-8'> |
|
82 | + <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Main::MAX_UPLOAD_SIZE."'>"; |
|
83 | 83 | ?> |
84 | 84 | <fieldset class="option_container"> |
85 | - <legend><strong><?php echo sprintf(_("%s Properties"),$uiElements->nomenclatureFed); ?></strong></legend> |
|
85 | + <legend><strong><?php echo sprintf(_("%s Properties"), $uiElements->nomenclatureFed); ?></strong></legend> |
|
86 | 86 | <?php |
87 | 87 | $optionDisplay = new \web\lib\admin\OptionDisplay($fed_options, \core\Options::LEVEL_FED); |
88 | 88 | echo $optionDisplay->prefilledOptionTable("fed"); |
@@ -90,5 +90,5 @@ discard block |
||
90 | 90 | <button type='button' class='newoption' onclick='getXML("fed")'><?php echo _("Add new option"); ?></button> |
91 | 91 | </fieldset> |
92 | 92 | <?php |
93 | - echo "<div><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_federation.php\"'>" . _("Discard changes") . "</button></div></form>"; |
|
93 | + echo "<div><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_federation.php\"'>"._("Discard changes")."</button></div></form>"; |
|
94 | 94 | echo $deco->footer(); |
@@ -20,7 +20,7 @@ discard block |
||
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 | $uiElements = new \web\lib\admin\UIElements(); |
@@ -57,30 +57,30 @@ discard block |
||
57 | 57 | <?php |
58 | 58 | echo sprintf(_("On this page, you can add a new %s to your %s. Please fill out the form below to send out an email invitation to the new %s administrator."), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed, $uiElements->nomenclatureInst); |
59 | 59 | if (\config\Main::DB['enforce-external-sync']) { |
60 | - echo "<p>" . sprintf(_("You can either register a known %s (as defined in the %s database) or create a totally new %s."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name'], $uiElements->nomenclatureInst) . "</p>"; |
|
61 | - echo "<p>" . sprintf(_("The latter one is typically for an %s which is yet in a testing phase and therefore doesn't appear in the %s database yet."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name']) . "</p>"; |
|
60 | + echo "<p>".sprintf(_("You can either register a known %s (as defined in the %s database) or create a totally new %s."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name'], $uiElements->nomenclatureInst)."</p>"; |
|
61 | + echo "<p>".sprintf(_("The latter one is typically for an %s which is yet in a testing phase and therefore doesn't appear in the %s database yet."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name'])."</p>"; |
|
62 | 62 | } |
63 | 63 | ?> |
64 | 64 | <hr/> |
65 | 65 | <img alt='Loading ...' src='../resources/images/icons/loading51.gif' id='spin' style='position:absolute;left: 50%; top: 50%; transform: translate(-100px, -50px); display:none;'> |
66 | 66 | <form name='sendinvite' action='inc/sendinvite.inc.php' method='post' accept-charset='UTF-8'> |
67 | 67 | <table> |
68 | - <caption><?php echo _("Invitation Details");?></caption> |
|
68 | + <caption><?php echo _("Invitation Details"); ?></caption> |
|
69 | 69 | <tr> |
70 | - <th class="wai-invisible" scope="col"><?php echo _("From database or ad-hoc?");?></th> |
|
71 | - <th class="wai-invisible" scope="col"><?php echo _("Name");?></th> |
|
72 | - <th class="wai-invisible" scope="col"><?php echo _("Type");?></th> |
|
73 | - <th class="wai-invisible" scope="col"><?php echo _("Country");?></th> |
|
70 | + <th class="wai-invisible" scope="col"><?php echo _("From database or ad-hoc?"); ?></th> |
|
71 | + <th class="wai-invisible" scope="col"><?php echo _("Name"); ?></th> |
|
72 | + <th class="wai-invisible" scope="col"><?php echo _("Type"); ?></th> |
|
73 | + <th class="wai-invisible" scope="col"><?php echo _("Country"); ?></th> |
|
74 | 74 | </tr> |
75 | 75 | <?php |
76 | 76 | if (\config\Main::DB['enforce-external-sync']) { |
77 | 77 | echo "<tr><td> |
78 | - <input type='radio' name='creation' value='existing'>" . sprintf(_("Existing %s:"), $uiElements->nomenclatureParticipant) . "</input> |
|
78 | + <input type='radio' name='creation' value='existing'>" . sprintf(_("Existing %s:"), $uiElements->nomenclatureParticipant)."</input> |
|
79 | 79 | </td>"; |
80 | 80 | |
81 | 81 | echo "<td colspan='3'> |
82 | 82 | <select id='externals' name='externals' onchange='document.sendinvite.creation[0].checked=true; document.sendinvite.mailaddr.value=this.options[this.selectedIndex].id;'> |
83 | - <option value='FREETEXT'>" . sprintf(_("--- select %s here ---"),$uiElements->nomenclatureParticipant) . "</option>"; |
|
83 | + <option value='FREETEXT'>" . sprintf(_("--- select %s here ---"), $uiElements->nomenclatureParticipant)."</option>"; |
|
84 | 84 | |
85 | 85 | foreach ($feds as $fed_value) { |
86 | 86 | $thefed = new \core\Federation(strtoupper($fed_value['value'])); |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | $entities = $thefed->listExternalEntities(TRUE, NULL); |
90 | 90 | |
91 | 91 | foreach ($entities as $v) { |
92 | - echo "<option id='" . $v['contactlist'] . "' value='" . $v['ID'] . "'>[" . $fed_value['value'] . "] " . $v['name'] . "</option>"; |
|
92 | + echo "<option id='".$v['contactlist']."' value='".$v['ID']."'>[".$fed_value['value']."] ".$v['name']."</option>"; |
|
93 | 93 | } |
94 | 94 | } |
95 | 95 | |
@@ -98,16 +98,16 @@ discard block |
||
98 | 98 | ?> |
99 | 99 | <tr> |
100 | 100 | <td> |
101 | - <input type='radio' name='creation' value='new'><?php echo sprintf(_("New %s"),$uiElements->nomenclatureParticipant); ?></input> |
|
101 | + <input type='radio' name='creation' value='new'><?php echo sprintf(_("New %s"), $uiElements->nomenclatureParticipant); ?></input> |
|
102 | 102 | </td> |
103 | 103 | <td> |
104 | 104 | <?php echo _("Name"); ?><input type='text' size='30' id='name' name='name' onchange='document.sendinvite.creation[1].checked = true'/> |
105 | 105 | </td> |
106 | 106 | <td> |
107 | 107 | <select name="participant_type"> |
108 | - <option value="IdPSP" selected><?php printf(_("%s and %s"),$uiElements->nomenclatureInst, $uiElements->nomenclatureHotspot)?></option> |
|
109 | - <option value="IdP"><?php printf(_("%s"),$uiElements->nomenclatureInst)?></option> |
|
110 | - <option value="SP"><?php printf(_("%s"),$uiElements->nomenclatureHotspot)?></option> |
|
108 | + <option value="IdPSP" selected><?php printf(_("%s and %s"), $uiElements->nomenclatureInst, $uiElements->nomenclatureHotspot)?></option> |
|
109 | + <option value="IdP"><?php printf(_("%s"), $uiElements->nomenclatureInst)?></option> |
|
110 | + <option value="SP"><?php printf(_("%s"), $uiElements->nomenclatureHotspot)?></option> |
|
111 | 111 | </select> |
112 | 112 | </td> |
113 | 113 | <td><?php echo $uiElements->nomenclatureFed; ?> |
@@ -20,7 +20,7 @@ discard block |
||
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 | $auth->authenticate(); |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | |
36 | 36 | // if we have a pushed close button, submit attributes and send user back to the overview page |
37 | 37 | // if external DB sync is disabled globally, the user never gets to this page. If he came here *anyway* -> send him back immediately. |
38 | -if ((isset($_POST['submitbutton']) && $_POST['submitbutton'] == web\lib\common\FormElements::BUTTON_CLOSE ) || \config\Main::DB['enforce-external-sync'] == FALSE) { |
|
38 | +if ((isset($_POST['submitbutton']) && $_POST['submitbutton'] == web\lib\common\FormElements::BUTTON_CLOSE) || \config\Main::DB['enforce-external-sync'] == FALSE) { |
|
39 | 39 | header("Location: ../overview_federation.php"); |
40 | 40 | exit; |
41 | 41 | } |
@@ -92,9 +92,9 @@ discard block |
||
92 | 92 | $cat = new \core\CAT(); |
93 | 93 | switch ($my_inst->getExternalDBSyncState()) { |
94 | 94 | case \core\IdP::EXTERNAL_DB_SYNCSTATE_SYNCED: |
95 | - printf(_("This %s is linked to the %s database."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name']) . "</p>"; |
|
96 | - echo "<p>" . sprintf(_("The following information about the IdP is stored in the %s DB and %s DB:"), \config\Main::APPEARANCE['productname'], \config\ConfAssistant::CONSORTIUM['display_name']) . "</p>"; |
|
97 | - echo "<table><tr><td>" . sprintf(_("Information in <strong>%s Database</strong>"), \config\Main::APPEARANCE['productname']) . "</td><td>" . sprintf(_("Information in <strong>%s Database</strong>"), \config\ConfAssistant::CONSORTIUM['display_name']) . "</td></tr>"; |
|
95 | + printf(_("This %s is linked to the %s database."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name'])."</p>"; |
|
96 | + echo "<p>".sprintf(_("The following information about the IdP is stored in the %s DB and %s DB:"), \config\Main::APPEARANCE['productname'], \config\ConfAssistant::CONSORTIUM['display_name'])."</p>"; |
|
97 | + echo "<table><tr><td>".sprintf(_("Information in <strong>%s Database</strong>"), \config\Main::APPEARANCE['productname'])."</td><td>".sprintf(_("Information in <strong>%s Database</strong>"), \config\ConfAssistant::CONSORTIUM['display_name'])."</td></tr>"; |
|
98 | 98 | echo "<tr><td>"; |
99 | 99 | // left-hand side: CAT DB |
100 | 100 | echo "<table>"; |
@@ -106,7 +106,7 @@ discard block |
||
106 | 106 | } else { |
107 | 107 | $language = \config\Main::LANGUAGES[$name['lang']]['display'] ?? "(unsupported language)"; |
108 | 108 | } |
109 | - echo "<tr><td>" . sprintf(_("%s Name (%s)"), $uiElements->nomenclatureInst, $language) . "</td><td>" . $name['value'] . "</td></tr>"; |
|
109 | + echo "<tr><td>".sprintf(_("%s Name (%s)"), $uiElements->nomenclatureInst, $language)."</td><td>".$name['value']."</td></tr>"; |
|
110 | 110 | } |
111 | 111 | |
112 | 112 | $admins = $my_inst->listOwners(); |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | if (count($username) == 0) { |
118 | 118 | $username[0]['value'] = _("Unnamed User"); |
119 | 119 | } |
120 | - echo "<tr><td>" . _("Administrator [invited as]") . "</td><td>" . $username[0]['value'] . " [" . $admin['MAIL'] . "]</td></tr>"; |
|
120 | + echo "<tr><td>"._("Administrator [invited as]")."</td><td>".$username[0]['value']." [".$admin['MAIL']."]</td></tr>"; |
|
121 | 121 | } |
122 | 122 | echo "</table>"; |
123 | 123 | // end of left-hand side |
@@ -125,38 +125,38 @@ discard block |
||
125 | 125 | // right-hand side: external DB |
126 | 126 | $externalid = $my_inst->getExternalDBId(); |
127 | 127 | if (is_bool($externalid)) { // we are in SYNCED state so this cannot happen |
128 | - throw new Exception("We are in SYNCSTATE_SYNCED but still there is no external DB Id available for the " . \config\ConfAssistant::CONSORTIUM['nomenclature_institution'] . "!"); |
|
128 | + throw new Exception("We are in SYNCSTATE_SYNCED but still there is no external DB Id available for the ".\config\ConfAssistant::CONSORTIUM['nomenclature_institution']."!"); |
|
129 | 129 | } |
130 | 130 | |
131 | 131 | $extinfo = $cat->getExternalDBEntityDetails($externalid); |
132 | 132 | |
133 | 133 | echo "<table>"; |
134 | 134 | foreach ($extinfo['names'] as $lang => $name) { |
135 | - echo "<tr><td>" . sprintf(_("%s Name (%s)"), $uiElements->nomenclatureInst, $lang) . "</td><td>$name</td>"; |
|
135 | + echo "<tr><td>".sprintf(_("%s Name (%s)"), $uiElements->nomenclatureInst, $lang)."</td><td>$name</td>"; |
|
136 | 136 | } |
137 | 137 | foreach ($extinfo['admins'] as $number => $admin_details) { |
138 | - echo "<tr><td>" . _("Administrator email") . "</td><td>" . $admin_details['email'] . "</td></tr>"; |
|
138 | + echo "<tr><td>"._("Administrator email")."</td><td>".$admin_details['email']."</td></tr>"; |
|
139 | 139 | } |
140 | 140 | echo "</table>"; |
141 | 141 | // end of right-hand side |
142 | 142 | echo "</td></tr></table>"; |
143 | - echo "<p>" . _("If this mapping is not correct any more, you can remove the link:") . " "; |
|
143 | + echo "<p>"._("If this mapping is not correct any more, you can remove the link:")." "; |
|
144 | 144 | echo "<form name='form-unlink-inst' action='inc/manageDBLink.inc.php?inst_id=$my_inst->identifier' method='post' accept-charset='UTF-8'>"; |
145 | - echo "<button type='submit' class='delete' name='submitbutton' id='submit' value='" . web\lib\common\FormElements::BUTTON_DELETE . "'>" . _("Unlink") . "</button></form>"; |
|
145 | + echo "<button type='submit' class='delete' name='submitbutton' id='submit' value='".web\lib\common\FormElements::BUTTON_DELETE."'>"._("Unlink")."</button></form>"; |
|
146 | 146 | break; |
147 | 147 | case \core\IdP::EXTERNAL_DB_SYNCSTATE_NOT_SYNCED: |
148 | 148 | $temparray = []; |
149 | - printf(_("This %s is not yet linked to the %s database."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name']) . " "; |
|
150 | - echo "<strong>" . _("This means that its profiles are not made available on the user download page.") . "</strong> "; |
|
149 | + printf(_("This %s is not yet linked to the %s database."), $uiElements->nomenclatureInst, \config\ConfAssistant::CONSORTIUM['display_name'])." "; |
|
150 | + echo "<strong>"._("This means that its profiles are not made available on the user download page.")."</strong> "; |
|
151 | 151 | printf(_("You can link it to the %s database below."), \config\ConfAssistant::CONSORTIUM['display_name']); |
152 | 152 | $candidates = $my_inst->getExternalDBSyncCandidates($my_inst->type); |
153 | 153 | echo "<br/><form name='form-link-inst' action='inc/manageDBLink.inc.php?inst_id=$my_inst->identifier' method='post' accept-charset='UTF-8'>"; |
154 | - printf(_("Please select an entity from the %s DB which corresponds to this CAT %s."), \config\ConfAssistant::CONSORTIUM['display_name'], $uiElements->nomenclatureInst) . " "; |
|
154 | + printf(_("Please select an entity from the %s DB which corresponds to this CAT %s."), \config\ConfAssistant::CONSORTIUM['display_name'], $uiElements->nomenclatureInst)." "; |
|
155 | 155 | if (count($candidates) > 0) { |
156 | 156 | printf(_("Particularly promising entries (names in CAT and %s DB are a 100%% match) are on top of the list."), \config\ConfAssistant::CONSORTIUM['display_name']); |
157 | 157 | } |
158 | 158 | echo "<table>"; |
159 | - echo "<tr><th>" . _("Link to this entity?") . "</th><th>" . sprintf(_("%s Name"), $uiElements->nomenclatureInst) . "</th><th>" . _("Administrators") . "</th></tr>"; |
|
159 | + echo "<tr><th>"._("Link to this entity?")."</th><th>".sprintf(_("%s Name"), $uiElements->nomenclatureInst)."</th><th>"._("Administrators")."</th></tr>"; |
|
160 | 160 | |
161 | 161 | foreach ($candidates as $candidate) { |
162 | 162 | $info = $cat->getExternalDBEntityDetails($candidate); |
@@ -166,7 +166,7 @@ discard block |
||
166 | 166 | } |
167 | 167 | echo "</td><td>"; |
168 | 168 | foreach ($info['admins'] as $number => $admin_details) { |
169 | - echo "[E-Mail] " . $admin_details['email'] . "<br/>"; |
|
169 | + echo "[E-Mail] ".$admin_details['email']."<br/>"; |
|
170 | 170 | } |
171 | 171 | echo "</td></tr>"; |
172 | 172 | $temparray[] = $candidate; |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | $buffer = ""; |
179 | 179 | |
180 | 180 | foreach ($unmappedentities as $v) { |
181 | - $buffer .= "<option value='" . $v['ID'] . "'>[ID " . $v['ID'] . "] " . $v['name'] . "</option>"; |
|
181 | + $buffer .= "<option value='".$v['ID']."'>[ID ".$v['ID']."] ".$v['name']."</option>"; |
|
182 | 182 | } |
183 | 183 | |
184 | 184 | if ($buffer != "") { |
@@ -189,9 +189,9 @@ discard block |
||
189 | 189 | } |
190 | 190 | // issue a big red warning if there are no link candidates at all in the federation |
191 | 191 | if (empty($buffer) && empty($candidates)) { |
192 | - echo "<tr><td style='color:#ff0000' colspan='2'>" . sprintf(_('There is no single unmapped %s in the external database for this %s!'), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed) . "</td></tr>"; |
|
192 | + echo "<tr><td style='color:#ff0000' colspan='2'>".sprintf(_('There is no single unmapped %s in the external database for this %s!'), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed)."</td></tr>"; |
|
193 | 193 | } |
194 | - echo "</table><button type='submit' name='submitbutton' id='submit' value='" . web\lib\common\FormElements::BUTTON_SAVE . "' disabled >" . _("Create Link") . "</button></form>"; |
|
194 | + echo "</table><button type='submit' name='submitbutton' id='submit' value='".web\lib\common\FormElements::BUTTON_SAVE."' disabled >"._("Create Link")."</button></form>"; |
|
195 | 195 | break; |
196 | 196 | default: |
197 | 197 | } |
@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | |
22 | 22 | namespace core; |
23 | 23 | |
24 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
24 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
25 | 25 | |
26 | 26 | $instMgmt = new \core\UserManagement(); |
27 | 27 | $deco = new \web\lib\admin\PageDecoration(); |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | <?php echo $uiElements->infoblock($user->getAttributes(), "user", "User"); ?> |
60 | 60 | <tr> |
61 | 61 | <td> |
62 | -<?php echo "" . _("Unique Identifier") ?> |
|
62 | +<?php echo ""._("Unique Identifier") ?> |
|
63 | 63 | </td> |
64 | 64 | <td> |
65 | 65 | </td> |
@@ -72,14 +72,14 @@ discard block |
||
72 | 72 | <div> |
73 | 73 | <?php |
74 | 74 | if (\config\Main::DB['USER']['readonly'] === FALSE) { |
75 | - echo "<a href='edit_user.php'><button>" . _("Edit User Details") . "</button></a>"; |
|
75 | + echo "<a href='edit_user.php'><button>"._("Edit User Details")."</button></a>"; |
|
76 | 76 | } |
77 | 77 | |
78 | 78 | if ($user->isFederationAdmin()) { |
79 | - echo "<form action='overview_federation.php' method='GET' accept-charset='UTF-8'><button type='submit'>" . sprintf(_('Click here for %s management tasks'), $uiElements->nomenclatureFed) . "</button></form>"; |
|
79 | + echo "<form action='overview_federation.php' method='GET' accept-charset='UTF-8'><button type='submit'>".sprintf(_('Click here for %s management tasks'), $uiElements->nomenclatureFed)."</button></form>"; |
|
80 | 80 | } |
81 | 81 | if ($user->isSuperadmin()) { |
82 | - echo "<form action='112365365321.php' method='GET' accept-charset='UTF-8'><button type='submit'>" . _('Click here to access the superadmin page') . "</button></form>"; |
|
82 | + echo "<form action='112365365321.php' method='GET' accept-charset='UTF-8'><button type='submit'>"._('Click here to access the superadmin page')."</button></form>"; |
|
83 | 83 | } |
84 | 84 | ?> |
85 | 85 | </div> |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
93 | 93 | $target = "https://wiki.geant.org/x/6Zg7Bw"; // Managed IdP manual |
94 | 94 | } |
95 | - $helptext = "<h3 style='display:inline;'>" . sprintf(_("(Need help? Refer to the <a href='%s'>%s administrator manual</a>)"), $target, $uiElements->nomenclatureInst) . "</h3>"; |
|
95 | + $helptext = "<h3 style='display:inline;'>".sprintf(_("(Need help? Refer to the <a href='%s'>%s administrator manual</a>)"), $target, $uiElements->nomenclatureInst)."</h3>"; |
|
96 | 96 | } else { |
97 | 97 | $helptext = ""; |
98 | 98 | } |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | // we need to run the Federation constructor |
102 | 102 | $cat = new \core\CAT; |
103 | 103 | /// first parameter: number of Identity Providers; second param is the literal configured term for 'Identity Provider' (you may or may not be able to add a plural suffix for your locale) |
104 | - echo "<h2>" . sprintf(ngettext("You are managing the following <span style='display:none'>%d </span>%s:", "You are managing the following <strong>%d</strong> %s:", sizeof($hasInst)), sizeof($hasInst), $uiElements->nomenclatureParticipant) . "</h2>"; |
|
104 | + echo "<h2>".sprintf(ngettext("You are managing the following <span style='display:none'>%d </span>%s:", "You are managing the following <strong>%d</strong> %s:", sizeof($hasInst)), sizeof($hasInst), $uiElements->nomenclatureParticipant)."</h2>"; |
|
105 | 105 | $instlist = []; |
106 | 106 | $my_idps = []; |
107 | 107 | $myFeds = []; |
@@ -124,7 +124,7 @@ discard block |
||
124 | 124 | } |
125 | 125 | ?> |
126 | 126 | <table class='user_overview'> |
127 | - <caption><?php echo sprintf(_("%s Management Overview",$uiElements->nomenclatureParticipant));?></caption> |
|
127 | + <caption><?php echo sprintf(_("%s Management Overview", $uiElements->nomenclatureParticipant)); ?></caption> |
|
128 | 128 | <tr> |
129 | 129 | <th scope='col'><?php echo sprintf(_("%s Name"), $uiElements->nomenclatureParticipant); ?></th> |
130 | 130 | <th scope="col"><?php echo sprintf(_("Other admins of this %s"), $uiElements->nomenclatureParticipant); ?></th> |
@@ -144,7 +144,7 @@ discard block |
||
144 | 144 | <?php |
145 | 145 | foreach ($myFeds as $fed_id => $fed_name) { |
146 | 146 | /// nomenclature 'fed', fed name, nomenclature 'inst' |
147 | - echo "<tr><td colspan='4'><strong>" . sprintf(_("%s %s: %s list"), $uiElements->nomenclatureFed, $fed_name, $uiElements->nomenclatureParticipant) . "</strong></td></tr>"; |
|
147 | + echo "<tr><td colspan='4'><strong>".sprintf(_("%s %s: %s list"), $uiElements->nomenclatureFed, $fed_name, $uiElements->nomenclatureParticipant)."</strong></td></tr>"; |
|
148 | 148 | |
149 | 149 | $fedOrganisations = $my_idps[$fed_id]; |
150 | 150 | asort($fedOrganisations); |
@@ -153,7 +153,7 @@ discard block |
||
153 | 153 | $the_inst = $oneinst['object']; |
154 | 154 | |
155 | 155 | echo "<tr>" |
156 | - . "<td>" . $oneinst['name'] . "</td>"; |
|
156 | + . "<td>".$oneinst['name']."</td>"; |
|
157 | 157 | echo "<td>"; |
158 | 158 | $admins = $the_inst->listOwners(); |
159 | 159 | $blessedUser = FALSE; |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | $coadmin = new \core\User($username['ID']); |
163 | 163 | $coadmin_name = $coadmin->getAttributes('user:realname'); |
164 | 164 | if (count($coadmin_name) > 0) { |
165 | - echo $coadmin_name[0]['value'] . "<br/>"; |
|
165 | + echo $coadmin_name[0]['value']."<br/>"; |
|
166 | 166 | unset($admins[$number]); |
167 | 167 | } |
168 | 168 | } else { // don't list self |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | } |
178 | 178 | echo "</td><td>"; |
179 | 179 | if ($blessedUser && \config\Main::DB['INST']['readonly'] === FALSE) { |
180 | - echo "<div style='white-space: nowrap;'><form method='post' action='inc/manageAdmins.inc.php?inst_id=" . $the_inst->identifier . "' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'><button type='submit'>" . _("Add/Remove Administrators") . "</button></form></div>"; |
|
180 | + echo "<div style='white-space: nowrap;'><form method='post' action='inc/manageAdmins.inc.php?inst_id=".$the_inst->identifier."' onsubmit='popupRedirectWindow(this); return false;' accept-charset='UTF-8'><button type='submit'>"._("Add/Remove Administrators")."</button></form></div>"; |
|
181 | 181 | } |
182 | 182 | echo "</td></tr>"; |
183 | 183 | } |
@@ -217,7 +217,7 @@ discard block |
||
217 | 217 | echo "</td><td>"; // danger zone |
218 | 218 | ?> |
219 | 219 | <form action='edit_participant_result.php?inst_id=<?php echo $the_inst->identifier; ?>' method='post' accept-charset='UTF-8'> |
220 | - <button class='delete' type='submit' name='submitbutton' value='<?php echo \web\lib\common\FormElements::BUTTON_DELETE; ?>' onclick="return confirm('<?php echo ( \config\ConfAssistant::CONSORTIUM['selfservice_registration'] === NULL ? sprintf(_("After deleting the %s, you can not recreate it yourself - you need a new invitation token from the %s administrator!"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed) . " " : "" ) . sprintf(_("Do you really want to delete your %s %s?"), $uiElements->nomenclatureParticipant, $my_inst->name); ?>')"><?php echo sprintf(_("Delete %s"), $uiElements->nomenclatureParticipant); ?></button> |
|
220 | + <button class='delete' type='submit' name='submitbutton' value='<?php echo \web\lib\common\FormElements::BUTTON_DELETE; ?>' onclick="return confirm('<?php echo (\config\ConfAssistant::CONSORTIUM['selfservice_registration'] === NULL ? sprintf(_("After deleting the %s, you can not recreate it yourself - you need a new invitation token from the %s administrator!"), $uiElements->nomenclatureInst, $uiElements->nomenclatureFed)." " : "").sprintf(_("Do you really want to delete your %s %s?"), $uiElements->nomenclatureParticipant, $my_inst->name); ?>')"><?php echo sprintf(_("Delete %s"), $uiElements->nomenclatureParticipant); ?></button> |
|
221 | 221 | </form> |
222 | 222 | <form action='edit_participant_result.php?inst_id=<?php echo $the_inst->identifier; ?>' method='post' accept-charset='UTF-8'> |
223 | 223 | <button class='delete' type='submit' name='submitbutton' value='<?php echo \web\lib\common\FormElements::BUTTON_FLUSH_AND_RESTART; ?>' onclick="return confirm('<?php echo sprintf(_("This action will delete all properties of the %s and start over the configuration from scratch. Do you really want to reset all settings of the %s %s?"), $uiElements->nomenclatureParticipant, $uiElements->nomenclatureParticipant, $my_inst->name); ?>')"><?php echo sprintf(_("Reset all %s settings"), $uiElements->nomenclatureParticipant); ?></button> |
@@ -230,18 +230,18 @@ discard block |
||
230 | 230 | </table> |
231 | 231 | <?php |
232 | 232 | } else { |
233 | - echo "<h2>" . sprintf(_("You are not managing any %s."), $uiElements->nomenclatureInst) . "</h2>"; |
|
233 | + echo "<h2>".sprintf(_("You are not managing any %s."), $uiElements->nomenclatureInst)."</h2>"; |
|
234 | 234 | } |
235 | 235 | if (\config\Main::DB['INST']['readonly'] === FALSE) { |
236 | 236 | if (\config\ConfAssistant::CONSORTIUM['selfservice_registration'] === NULL) { |
237 | - echo "<p>" . sprintf(_("Please ask your %s administrator to invite you to become an %s administrator."), $uiElements->nomenclatureFed, $uiElements->nomenclatureParticipant) . "</p>"; |
|
237 | + echo "<p>".sprintf(_("Please ask your %s administrator to invite you to become an %s administrator."), $uiElements->nomenclatureFed, $uiElements->nomenclatureParticipant)."</p>"; |
|
238 | 238 | echo "<hr/> |
239 | 239 | <div style='white-space: nowrap;'> |
240 | 240 | <form action='action_enrollment.php' method='get' accept-charset='UTF-8'>" . |
241 | - sprintf(_("Did you receive an invitation token to manage an %s? Please paste it here:"), $uiElements->nomenclatureParticipant) . |
|
241 | + sprintf(_("Did you receive an invitation token to manage an %s? Please paste it here:"), $uiElements->nomenclatureParticipant). |
|
242 | 242 | " <input type='text' id='token' name='token'/> |
243 | 243 | <button type='submit'>" . |
244 | - _("Go!") . " |
|
244 | + _("Go!")." |
|
245 | 245 | </button> |
246 | 246 | </form> |
247 | 247 | </div>"; |
@@ -250,7 +250,7 @@ discard block |
||
250 | 250 | <div style='white-space: nowrap;'> |
251 | 251 | <form action='action_enrollment.php' method='get'><button type='submit' accept-charset='UTF-8'> |
252 | 252 | <input type='hidden' id='token' name='token' value='SELF-REGISTER'/>" . |
253 | - sprintf(_("New %s Registration"), $uiElements->nomenclatureParticipant) . " |
|
253 | + sprintf(_("New %s Registration"), $uiElements->nomenclatureParticipant)." |
|
254 | 254 | </button> |
255 | 255 | </form> |
256 | 256 | </div>"; |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | * <base_url>/copyright.php after deploying the software |
21 | 21 | */ |
22 | 22 | |
23 | -require_once dirname(dirname(dirname(__FILE__))) . "/config/_config.php"; |
|
23 | +require_once dirname(dirname(dirname(__FILE__)))."/config/_config.php"; |
|
24 | 24 | |
25 | 25 | $auth = new \web\lib\admin\Authentication(); |
26 | 26 | $loggerInstance = new \core\common\Logging(); |
@@ -33,15 +33,15 @@ discard block |
||
33 | 33 | $myInstOriginal = $validator->existingIdP($_GET['inst_id'], $_SESSION['user']); |
34 | 34 | $instId = $myInstOriginal->identifier; |
35 | 35 | |
36 | -$hello = _("To whom it may concern,") . "\n\n"; |
|
37 | -$bye = _("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" . |
|
38 | - _("Greetings, ") . "\n\n" . |
|
36 | +$hello = _("To whom it may concern,")."\n\n"; |
|
37 | +$bye = _("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". |
|
38 | + _("Greetings, ")."\n\n". |
|
39 | 39 | \config\Main::APPEARANCE['productname_long']; |
40 | 40 | |
41 | 41 | switch ($_POST['submitbutton']) { |
42 | 42 | case web\lib\common\FormElements::BUTTON_DELETE: |
43 | 43 | $myInstOriginal->destroy(); |
44 | - $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP " . $instId); |
|
44 | + $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP ".$instId); |
|
45 | 45 | header("Location: overview_user.php"); |
46 | 46 | exit; |
47 | 47 | case web\lib\common\FormElements::BUTTON_FLUSH_AND_RESTART: |
@@ -51,9 +51,9 @@ discard block |
||
51 | 51 | } |
52 | 52 | // flush all IdP attributes and send user to creation wizard |
53 | 53 | $myInstOriginal->flushAttributes(); |
54 | - $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP starting over" . $instId); |
|
55 | - $text = $hello . |
|
56 | - sprintf(_("the %s %s / %s / (previously known as) '%s' has deleted all properties and is starting over freshly. This means that its not recognisable by its name any more, and it may assume a different name in the future. You will get another mail if and when the name change happens."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name) . "\n\n" . |
|
54 | + $loggerInstance->writeAudit($_SESSION['user'], "DEL", "IdP starting over".$instId); |
|
55 | + $text = $hello. |
|
56 | + sprintf(_("the %s %s / %s / (previously known as) '%s' has deleted all properties and is starting over freshly. This means that its not recognisable by its name any more, and it may assume a different name in the future. You will get another mail if and when the name change happens."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name)."\n\n". |
|
57 | 57 | $bye; |
58 | 58 | $fed = new core\Federation($myInstOriginal->federation); |
59 | 59 | foreach ($fed->listFederationAdmins() as $id) { |
@@ -72,19 +72,19 @@ discard block |
||
72 | 72 | exit(0); |
73 | 73 | } |
74 | 74 | $inst_name = $myInstOriginal->name; |
75 | - echo "<h1>" . sprintf(_("Submitted attributes for IdP '%s'"), $inst_name) . "</h1>"; |
|
75 | + echo "<h1>".sprintf(_("Submitted attributes for IdP '%s'"), $inst_name)."</h1>"; |
|
76 | 76 | echo "<table>"; |
77 | 77 | echo $optionParser->processSubmittedFields($myInstOriginal, $_POST, $_FILES); |
78 | 78 | echo "</table>"; |
79 | 79 | // delete cached logo, if present |
80 | - $dir = ROOT . '/web/downloads/logos/'; |
|
81 | - $globResult = glob($dir . $myInstOriginal->identifier . "_*.png"); |
|
80 | + $dir = ROOT.'/web/downloads/logos/'; |
|
81 | + $globResult = glob($dir.$myInstOriginal->identifier."_*.png"); |
|
82 | 82 | if ($globResult === FALSE) { // we should catch the improbable error condition |
83 | 83 | $globResult = []; |
84 | 84 | } |
85 | 85 | array_map('unlink', $globResult); |
86 | 86 | $loggerInstance->debug(4, "UNLINK from $dir\n"); |
87 | - $loggerInstance->writeAudit($_SESSION['user'], "MOD", "IdP " . $myInstOriginal->identifier . " - attributes changed"); |
|
87 | + $loggerInstance->writeAudit($_SESSION['user'], "MOD", "IdP ".$myInstOriginal->identifier." - attributes changed"); |
|
88 | 88 | |
89 | 89 | // re-instantiate ourselves... profiles need fresh data |
90 | 90 | $myInstReinstantiated = $validator->existingIdP($_GET['inst_id'], $_SESSION['user']); |
@@ -93,10 +93,10 @@ discard block |
||
93 | 93 | if (count($significantChanges) > 0) { |
94 | 94 | // send a notification/alert mail to someone we know is in charge |
95 | 95 | /// were made to the *Identity Provider* *LU* / integer number of IdP / (previously known as) Name |
96 | - $text = $hello . sprintf(_("significant changes were made to the %s %s / %s / (previously known as) '%s'."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name) . "\n\n"; |
|
96 | + $text = $hello.sprintf(_("significant changes were made to the %s %s / %s / (previously known as) '%s'."), $ui->nomenclatureInst, strtoupper($myInstOriginal->federation), $myInstOriginal->identifier, $myInstOriginal->name)."\n\n"; |
|
97 | 97 | if (isset($significantChanges[\core\IdP::INSTNAME_CHANGED])) { |
98 | - $text .= sprintf(_("The %s has changed its name. The details are below:"), $ui->nomenclatureInst) . "\n\n"; |
|
99 | - $text .= $significantChanges[\core\IdP::INSTNAME_CHANGED] . "\n\n"; |
|
98 | + $text .= sprintf(_("The %s has changed its name. The details are below:"), $ui->nomenclatureInst)."\n\n"; |
|
99 | + $text .= $significantChanges[\core\IdP::INSTNAME_CHANGED]."\n\n"; |
|
100 | 100 | } |
101 | 101 | $text .= $bye; |
102 | 102 | // (currently, send hard-wired to NRO - future: for linked insts, check eduroam DBv2 and send to registered admins directly) |
@@ -112,12 +112,12 @@ discard block |
||
112 | 112 | |
113 | 113 | if (isset(\config\ConfAssistant::CONSORTIUM['ssid']) && count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0) { |
114 | 114 | foreach (\config\ConfAssistant::CONSORTIUM['ssid'] as $ssidname) { |
115 | - $ssids[] = $ssidname . " " . (isset(\config\ConfAssistant::CONSORTIUM['tkipsupport']) && \config\ConfAssistant::CONSORTIUM['tkipsupport'] === TRUE ? _("(WPA2/AES and WPA/TKIP)") : _("(WPA2/AES)") ); |
|
115 | + $ssids[] = $ssidname." ".(isset(\config\ConfAssistant::CONSORTIUM['tkipsupport']) && \config\ConfAssistant::CONSORTIUM['tkipsupport'] === TRUE ? _("(WPA2/AES and WPA/TKIP)") : _("(WPA2/AES)")); |
|
116 | 116 | } |
117 | 117 | } |
118 | 118 | |
119 | 119 | foreach ($myInstReinstantiated->getAttributes("media:SSID") as $ssidname) { |
120 | - $ssids[] = $ssidname['value'] . " " . _("(WPA2/AES)"); |
|
120 | + $ssids[] = $ssidname['value']." "._("(WPA2/AES)"); |
|
121 | 121 | } |
122 | 122 | |
123 | 123 | echo "<table>"; |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | if (count($ssids) > 0) { |
126 | 126 | $printedlist = ""; |
127 | 127 | foreach ($ssids as $names) { |
128 | - $printedlist = $printedlist . "$names "; |
|
128 | + $printedlist = $printedlist."$names "; |
|
129 | 129 | } |
130 | 130 | echo $uiElements->boxOkay(sprintf(_("Your installers will configure the following SSIDs: <strong>%s</strong>"), $printedlist), _("SSIDs configured")); |
131 | 131 | } |
@@ -153,7 +153,7 @@ discard block |
||
153 | 153 | // did we get an email address? then, show the silverbullet jumpstart button |
154 | 154 | // otherwise, issue a smartass comment |
155 | 155 | if (count($myInstReinstantiated->getAttributes("support:email")) > 0) { |
156 | - echo "<form method='post' action='edit_silverbullet.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . sprintf(_("Continue to %s properties"), \core\ProfileSilverbullet::PRODUCTNAME) . "</button></form>"; |
|
156 | + echo "<form method='post' action='edit_silverbullet.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>".sprintf(_("Continue to %s properties"), \core\ProfileSilverbullet::PRODUCTNAME)."</button></form>"; |
|
157 | 157 | } else { |
158 | 158 | echo "<table>"; |
159 | 159 | echo $uiElements->boxError(sprintf(_("You did not submit an e-mail address. This is required for %s. Please go to the %s dashboard and edit your helpdesk settings to include a helpdesk e-mail address."), core\ProfileSilverbullet::PRODUCTNAME, $ui->nomenclatureInst), _("No support e-mail!")); |
@@ -161,10 +161,10 @@ discard block |
||
161 | 161 | } |
162 | 162 | } |
163 | 163 | if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL") { |
164 | - echo "<br/><form method='post' action='edit_profile.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . _("Continue to RADIUS/EAP profile definition") . "</button></form>"; |
|
164 | + echo "<br/><form method='post' action='edit_profile.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>"._("Continue to RADIUS/EAP profile definition")."</button></form>"; |
|
165 | 165 | } |
166 | 166 | } |
167 | - echo "<br/><form method='post' action='overview_user.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>" . _("Continue to dashboard") . "</button></form>"; |
|
167 | + echo "<br/><form method='post' action='overview_user.php?inst_id=$my_inst->identifier' accept-charset='UTF-8'><button type='submit'>"._("Continue to dashboard")."</button></form>"; |
|
168 | 168 | |
169 | 169 | break; |
170 | 170 | default: |
@@ -19,7 +19,7 @@ discard block |
||
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(); |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | $inst_name = $my_inst->name; |
40 | 40 | |
41 | 41 | if ($wizardStyle) { |
42 | - echo $deco->defaultPagePrelude(sprintf(_("%s: %s enrollment wizard (step 2)"), \config\Main::APPEARANCE['productname'], $uiElements->nomenclatureParticipant)); |
|
42 | + echo $deco->defaultPagePrelude(sprintf(_("%s: %s enrollment wizard (step 2)"), \config\Main::APPEARANCE['productname'], $uiElements->nomenclatureParticipant)); |
|
43 | 43 | } else { |
44 | 44 | echo $deco->defaultPagePrelude(sprintf(_("%s: Editing %s '%s'"), \config\Main::APPEARANCE['productname'], $uiElements->nomenclatureParticipant, $inst_name)); |
45 | 45 | } |
@@ -80,13 +80,13 @@ discard block |
||
80 | 80 | ?> |
81 | 81 | </h1> |
82 | 82 | <div class='infobox'> |
83 | - <h2><?php $tablecaption = sprintf(_("%s general properties"), $uiElements->nomenclatureParticipant); echo $tablecaption;?></h2> |
|
83 | + <h2><?php $tablecaption = sprintf(_("%s general properties"), $uiElements->nomenclatureParticipant); echo $tablecaption; ?></h2> |
|
84 | 84 | <table> |
85 | - <caption><?php echo $tablecaption;?></caption> |
|
85 | + <caption><?php echo $tablecaption; ?></caption> |
|
86 | 86 | <tr> |
87 | - <th class="wai-invisible" scope="col"><?php echo _("Property Type");?></th> |
|
88 | - <th class="wai-invisible" scope="col"><?php echo _("Language if applicable");?></th> |
|
89 | - <th class="wai-invisible" scope="col"><?php echo _("Property Value");?></th> |
|
87 | + <th class="wai-invisible" scope="col"><?php echo _("Property Type"); ?></th> |
|
88 | + <th class="wai-invisible" scope="col"><?php echo _("Language if applicable"); ?></th> |
|
89 | + <th class="wai-invisible" scope="col"><?php echo _("Property Value"); ?></th> |
|
90 | 90 | </tr> |
91 | 91 | |
92 | 92 | <tr> |
@@ -101,12 +101,12 @@ discard block |
||
101 | 101 | </table> |
102 | 102 | </div> |
103 | 103 | <?php |
104 | - echo "<form enctype='multipart/form-data' action='edit_participant_result.php?inst_id=$my_inst->identifier" . ($wizardStyle ? "&wizard=true" : "") . "' method='post' accept-charset='UTF-8'> |
|
105 | - <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Main::MAX_UPLOAD_SIZE . "'>"; |
|
104 | + echo "<form enctype='multipart/form-data' action='edit_participant_result.php?inst_id=$my_inst->identifier".($wizardStyle ? "&wizard=true" : "")."' method='post' accept-charset='UTF-8'> |
|
105 | + <input type='hidden' name='MAX_FILE_SIZE' value='" . \config\Main::MAX_UPLOAD_SIZE."'>"; |
|
106 | 106 | |
107 | 107 | if ($wizardStyle) { |
108 | - echo "<p>" . |
|
109 | - sprintf(_("Hello, newcomer. The %s is new to us. This wizard will ask you several questions about it, so that we can generate beautiful profiles for you in the end. All of the information below is optional, but it is important to fill out as many fields as possible for the benefit of your end users."), $uiElements->nomenclatureParticipant) . "</p>"; |
|
108 | + echo "<p>". |
|
109 | + sprintf(_("Hello, newcomer. The %s is new to us. This wizard will ask you several questions about it, so that we can generate beautiful profiles for you in the end. All of the information below is optional, but it is important to fill out as many fields as possible for the benefit of your end users."), $uiElements->nomenclatureParticipant)."</p>"; |
|
110 | 110 | } |
111 | 111 | $optionDisplay = new web\lib\admin\OptionDisplay($idpoptions, \core\Options::LEVEL_IDP); |
112 | 112 | ?> |
@@ -114,11 +114,11 @@ discard block |
||
114 | 114 | <legend><strong><?php echo _("General Information"); ?></strong></legend> |
115 | 115 | <?php |
116 | 116 | if ($wizardStyle) { |
117 | - echo "<p>" . |
|
118 | - _("Some properties are valid across all deployment profiles. This is the place where you can describe those properties in a fine-grained way. The solicited information is used as follows:") . "</p> |
|
117 | + echo "<p>". |
|
118 | + _("Some properties are valid across all deployment profiles. This is the place where you can describe those properties in a fine-grained way. The solicited information is used as follows:")."</p> |
|
119 | 119 | <ul> |
120 | - <li>" . _("<strong>Logo</strong>: When you submit a logo, we will embed this logo into all installers where a custom logo is possible. We accept any image format, but for best results, we suggest SVG. If you don't upload a logo, we will use the generic logo instead (see top-right corner of this page).") . "</li> |
|
121 | - <li>" . sprintf(_("<strong>Name</strong>: The %s may have names in multiple languages. It is recommended to always populate at least the 'default/other' language, as it is used as a fallback if the system does not have a name in the exact language the user requests a download in."),$uiElements->nomenclatureParticipant) . "</li>"; |
|
120 | + <li>" . _("<strong>Logo</strong>: When you submit a logo, we will embed this logo into all installers where a custom logo is possible. We accept any image format, but for best results, we suggest SVG. If you don't upload a logo, we will use the generic logo instead (see top-right corner of this page).")."</li> |
|
121 | + <li>" . sprintf(_("<strong>Name</strong>: The %s may have names in multiple languages. It is recommended to always populate at least the 'default/other' language, as it is used as a fallback if the system does not have a name in the exact language the user requests a download in."), $uiElements->nomenclatureParticipant)."</li>"; |
|
122 | 122 | echo "</ul>"; |
123 | 123 | } |
124 | 124 | echo $optionDisplay->prefilledOptionTable("general"); |
@@ -132,47 +132,47 @@ discard block |
||
132 | 132 | <legend><strong><?php echo _("Media Properties"); ?></strong></legend> |
133 | 133 | <?php |
134 | 134 | if ($wizardStyle) { |
135 | - echo "<p>" . |
|
136 | - sprintf(_("In this section, you define on which media %s should be configured on user devices."), \config\ConfAssistant::CONSORTIUM['display_name']) . "</p> |
|
135 | + echo "<p>". |
|
136 | + sprintf(_("In this section, you define on which media %s should be configured on user devices."), \config\ConfAssistant::CONSORTIUM['display_name'])."</p> |
|
137 | 137 | <ul>"; |
138 | 138 | echo "<li>"; |
139 | - echo "<strong>" . ( count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0 ? _("Additional SSIDs:") : _("SSIDs:")) . " </strong>"; |
|
139 | + echo "<strong>".(count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0 ? _("Additional SSIDs:") : _("SSIDs:"))." </strong>"; |
|
140 | 140 | if (count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0) { |
141 | 141 | $ssidlist = ""; |
142 | 142 | foreach (\config\ConfAssistant::CONSORTIUM['ssid'] as $ssid) { |
143 | - $ssidlist .= ", '<strong>" . $ssid . "</strong>'"; |
|
143 | + $ssidlist .= ", '<strong>".$ssid."</strong>'"; |
|
144 | 144 | } |
145 | 145 | $ssidlist = substr($ssidlist, 2); |
146 | 146 | echo sprintf(ngettext("We will always configure this SSID for WPA2/AES: %s.", "We will always configure these SSIDs for WPA2/AES: %s.", count(\config\ConfAssistant::CONSORTIUM['ssid'])), $ssidlist); |
147 | 147 | if (\config\ConfAssistant::CONSORTIUM['tkipsupport']) { |
148 | - echo " " . _("They will also be configured for WPA/TKIP if the device supports multiple encryption types."); |
|
148 | + echo " "._("They will also be configured for WPA/TKIP if the device supports multiple encryption types."); |
|
149 | 149 | } |
150 | - echo "<br/>" . sprintf(_("It is also possible to define custom additional SSIDs with the option '%s' below."), $uiElements->displayName("media:SSID")); |
|
150 | + echo "<br/>".sprintf(_("It is also possible to define custom additional SSIDs with the option '%s' below."), $uiElements->displayName("media:SSID")); |
|
151 | 151 | } else { |
152 | 152 | echo _("Please configure which SSIDs should be configured in the installers."); |
153 | 153 | } |
154 | - echo " " . _("By default, we will only configure the SSIDs with WPA2/AES encryption. By using the '(with WPA/TKIP)' option you can specify that we should include legacy support for WPA/TKIP where possible."); |
|
154 | + echo " "._("By default, we will only configure the SSIDs with WPA2/AES encryption. By using the '(with WPA/TKIP)' option you can specify that we should include legacy support for WPA/TKIP where possible."); |
|
155 | 155 | echo "</li>"; |
156 | 156 | |
157 | 157 | echo "<li>"; |
158 | - echo "<strong>" . ( count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0 ? _("Additional Hotspot 2.0 / Passpoint Consortia:") : _("Hotspot 2.0 / Passpoint Consortia:")) . " </strong>"; |
|
158 | + echo "<strong>".(count(\config\ConfAssistant::CONSORTIUM['ssid']) > 0 ? _("Additional Hotspot 2.0 / Passpoint Consortia:") : _("Hotspot 2.0 / Passpoint Consortia:"))." </strong>"; |
|
159 | 159 | if (count(\config\ConfAssistant::CONSORTIUM['interworking-consortium-oi']) > 0) { |
160 | 160 | $consortiumlist = ""; |
161 | 161 | foreach (\config\ConfAssistant::CONSORTIUM['interworking-consortium-oi'] as $oi) { |
162 | - $consortiumlist .= ", '<strong>" . $oi . "</strong>'"; |
|
162 | + $consortiumlist .= ", '<strong>".$oi."</strong>'"; |
|
163 | 163 | } |
164 | 164 | $consortiumlist = substr($consortiumlist, 2); |
165 | 165 | echo sprintf(ngettext("We will always configure this Consortium OI: %s.", "We will always configure these Consortium OIs: %s.", count(\config\ConfAssistant::CONSORTIUM['interworking-consortium-oi'])), $consortiumlist); |
166 | 166 | |
167 | - echo "<br/>" . sprintf(_("It is also possible to define custom additional OIs with the option '%s' below."), $uiElements->displayName("media:consortium_OI")); |
|
167 | + echo "<br/>".sprintf(_("It is also possible to define custom additional OIs with the option '%s' below."), $uiElements->displayName("media:consortium_OI")); |
|
168 | 168 | } else { |
169 | 169 | echo _("Please configure which Consortium OIs should be configured in the installers."); |
170 | 170 | } |
171 | 171 | echo "</li>"; |
172 | - echo "<li><strong>" . _("Support for wired IEEE 802.1X:") . " </strong>" |
|
173 | - . _("If you want to configure your users' devices with IEEE 802.1X support for wired ethernet, please check the corresponding box. Note that this makes the installation process a bit more difficult on some platforms (Windows: needs administrator privileges; Apple: attempting to install a profile with wired support on a device without an active wired ethernet card will fail).") . |
|
172 | + echo "<li><strong>"._("Support for wired IEEE 802.1X:")." </strong>" |
|
173 | + . _("If you want to configure your users' devices with IEEE 802.1X support for wired ethernet, please check the corresponding box. Note that this makes the installation process a bit more difficult on some platforms (Windows: needs administrator privileges; Apple: attempting to install a profile with wired support on a device without an active wired ethernet card will fail)."). |
|
174 | 174 | "</li>"; |
175 | - echo "<li><strong>" . _("Removal of bootstrap/onboarding SSIDs:") . " </strong>" |
|
175 | + echo "<li><strong>"._("Removal of bootstrap/onboarding SSIDs:")." </strong>" |
|
176 | 176 | . _("If you use a captive portal to distribute configurations, you may want to unconfigure/disable that SSID after the bootstrap process. With this option, the SSID will either be removed, or be defined as 'Only connect manually'.") |
177 | 177 | . "</li>"; |
178 | 178 | echo "</ul>"; |
@@ -188,16 +188,16 @@ discard block |
||
188 | 188 | echo "<p>"._("This section can be used to upload specific Terms of Use for your users and to display details of how your users can reach your local helpdesk.")."</p>"; |
189 | 189 | |
190 | 190 | if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_RADIUS'] == "LOCAL") { |
191 | - echo "<p>" . |
|
191 | + echo "<p>". |
|
192 | 192 | |
193 | - sprintf(_("Do you provide helpdesk services for your users? If so, it would be nice if you would tell us the pointers to this helpdesk."),$uiElements->nomenclatureParticipant) . "</p>" . |
|
194 | - "<p>" . |
|
195 | - _("If you enter a value here, it will be added to the installers for all your users, and will be displayed on the download page. If you operate separate helpdesks for different user groups (we call this 'profiles') specify per-profile helpdesk information later in this wizard. If you operate no help desk at all, just leave these fields empty.") . "</p>"; |
|
193 | + sprintf(_("Do you provide helpdesk services for your users? If so, it would be nice if you would tell us the pointers to this helpdesk."), $uiElements->nomenclatureParticipant)."</p>". |
|
194 | + "<p>". |
|
195 | + _("If you enter a value here, it will be added to the installers for all your users, and will be displayed on the download page. If you operate separate helpdesks for different user groups (we call this 'profiles') specify per-profile helpdesk information later in this wizard. If you operate no help desk at all, just leave these fields empty.")."</p>"; |
|
196 | 196 | if (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
197 | - echo "<p>" . sprintf(_("For %s deployments, providing at least a local e-mail contact is required."), core\ProfileSilverbullet::PRODUCTNAME) ." " . _("This is the contact point for your end users' level 1 support.") . "</p>"; |
|
197 | + echo "<p>".sprintf(_("For %s deployments, providing at least a local e-mail contact is required."), core\ProfileSilverbullet::PRODUCTNAME)." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
198 | 198 | } |
199 | 199 | } elseif (\config\Main::FUNCTIONALITY_LOCATIONS['CONFASSISTANT_SILVERBULLET'] == "LOCAL") { |
200 | - echo "<p>". _("Providing at least a local support e-mail contact is required.")." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
200 | + echo "<p>"._("Providing at least a local support e-mail contact is required.")." "._("This is the contact point for your end users' level 1 support.")."</p>"; |
|
201 | 201 | } |
202 | 202 | |
203 | 203 | } |
@@ -207,8 +207,8 @@ discard block |
||
207 | 207 | <button type='button' class='newoption' onclick='getXML("support")'><?php echo _("Add new option"); ?></button></fieldset> |
208 | 208 | <?php |
209 | 209 | if ($wizardStyle) { |
210 | - echo "<p>" . sprintf(_("When you are sure that everything is correct, please click on %sContinue ...%s"), "<button type='submit' name='submitbutton' value='" . web\lib\common\FormElements::BUTTON_CONTINUE . "'>", "</button>") . "</p></form>"; |
|
210 | + echo "<p>".sprintf(_("When you are sure that everything is correct, please click on %sContinue ...%s"), "<button type='submit' name='submitbutton' value='".web\lib\common\FormElements::BUTTON_CONTINUE."'>", "</button>")."</p></form>"; |
|
211 | 211 | } else { |
212 | - echo "<div><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_user.php\"'>" . _("Discard changes") . "</button></div></form>"; |
|
212 | + echo "<div><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_user.php\"'>"._("Discard changes")."</button></div></form>"; |
|
213 | 213 | } |
214 | 214 | echo $deco->footer(); |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | * <base_url>/copyright.php after deploying the software |
20 | 20 | */ |
21 | 21 | |
22 | -require dirname(dirname(dirname(dirname(__FILE__)))) . "/config/_config.php"; |
|
22 | +require dirname(dirname(dirname(dirname(__FILE__))))."/config/_config.php"; |
|
23 | 23 | $colour1 = \config\Main::APPEARANCE['colour1']; |
24 | 24 | $colour2 = \config\Main::APPEARANCE['colour2']; |
25 | 25 | header('Content-type: text/css; charset=utf-8'); |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | } |
30 | 30 | |
31 | 31 | body { |
32 | - background: <?php echo $colour1;?>; |
|
32 | + background: <?php echo $colour1; ?>; |
|
33 | 33 | color: #000000; |
34 | 34 | font-family:Verdana, Arial, Helvetica, sans-serif; |
35 | 35 | font-size:11px; |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | } |
53 | 53 | |
54 | 54 | button { |
55 | - background: <?php echo $colour2;?>; |
|
55 | + background: <?php echo $colour2; ?>; |
|
56 | 56 | color: #FFFFFF; |
57 | 57 | min-height: 23px; |
58 | 58 | border-left-style: outset; |
@@ -403,7 +403,7 @@ discard block |
||
403 | 403 | |
404 | 404 | span.edu_cat { |
405 | 405 | font-weight: bold; |
406 | - color: <?php echo $colour2;?>; |
|
406 | + color: <?php echo $colour2; ?>; |
|
407 | 407 | } |
408 | 408 | |
409 | 409 | span.tooltip { |
@@ -511,7 +511,7 @@ discard block |
||
511 | 511 | border-bottom-style:solid; |
512 | 512 | border-top-width:5px; |
513 | 513 | border-bottom-width:5px; |
514 | - border-color: <?php echo $colour1;?>; |
|
514 | + border-color: <?php echo $colour1; ?>; |
|
515 | 515 | padding-left:30px; |
516 | 516 | } |
517 | 517 | |
@@ -581,7 +581,7 @@ discard block |
||
581 | 581 | } |
582 | 582 | |
583 | 583 | #close_button { |
584 | - background: <?php echo $colour2;?>; |
|
584 | + background: <?php echo $colour2; ?>; |
|
585 | 585 | color: #FFFFFF; |
586 | 586 | height: 23px; |
587 | 587 | border-left-style: inset; |
@@ -656,7 +656,7 @@ discard block |
||
656 | 656 | width: 30em; |
657 | 657 | padding-left: 10px; |
658 | 658 | padding-right: 0px; |
659 | - background: <?php echo $colour2;?>; |
|
659 | + background: <?php echo $colour2; ?>; |
|
660 | 660 | color: white; |
661 | 661 | box-shadow: 10px 10px 5px #888888; |
662 | 662 | } |
@@ -703,7 +703,7 @@ discard block |
||
703 | 703 | padding-top: 4px; |
704 | 704 | padding-bottom: 12px; |
705 | 705 | padding-left: 30px; |
706 | - background: <?php echo $colour1;?>; |
|
706 | + background: <?php echo $colour1; ?>; |
|
707 | 707 | text-align: left; |
708 | 708 | text-shadow: 10px 10px 5px #888888; |
709 | 709 | } |
@@ -713,9 +713,9 @@ discard block |
||
713 | 713 | border-bottom-style:solid; |
714 | 714 | border-top-width:5px; |
715 | 715 | border-bottom-width:5px; |
716 | - border-color: <?php echo $colour1;?>; |
|
716 | + border-color: <?php echo $colour1; ?>; |
|
717 | 717 | padding-left:30px; |
718 | - color: <?php echo $colour2;?>; |
|
718 | + color: <?php echo $colour2; ?>; |
|
719 | 719 | } |
720 | 720 | |
721 | 721 | #heading h1 { |
@@ -734,7 +734,7 @@ discard block |
||
734 | 734 | text-align: justify; |
735 | 735 | border-bottom-style:solid; |
736 | 736 | border-bottom-width:5px; |
737 | - border-color: <?php echo $colour1;?>; |
|
737 | + border-color: <?php echo $colour1; ?>; |
|
738 | 738 | font-size: 11px; |
739 | 739 | font-weight: normal; |
740 | 740 | } |
@@ -781,7 +781,7 @@ discard block |
||
781 | 781 | |
782 | 782 | #faq { |
783 | 783 | padding: 20px; |
784 | - color: <?php echo $colour2;?>; |
|
784 | + color: <?php echo $colour2; ?>; |
|
785 | 785 | background: #ffffff; |
786 | 786 | } |
787 | 787 | |
@@ -833,7 +833,7 @@ discard block |
||
833 | 833 | |
834 | 834 | #line1 { |
835 | 835 | top:145px; |
836 | - color: <?php echo $colour2;?>; |
|
836 | + color: <?php echo $colour2; ?>; |
|
837 | 837 | font-size:20px; |
838 | 838 | } |
839 | 839 | |
@@ -880,7 +880,7 @@ discard block |
||
880 | 880 | |
881 | 881 | #front_page_leftmenu { |
882 | 882 | border-right:solid; |
883 | - border-color: <?php echo $colour1;?>; |
|
883 | + border-color: <?php echo $colour1; ?>; |
|
884 | 884 | border-width:5px; |
885 | 885 | min-height:400px; |
886 | 886 | padding-left: 10px; |
@@ -905,11 +905,11 @@ discard block |
||
905 | 905 | } |
906 | 906 | |
907 | 907 | a:link { |
908 | - color:<?php echo $colour2;?>; |
|
908 | + color:<?php echo $colour2; ?>; |
|
909 | 909 | } |
910 | 910 | |
911 | 911 | a:visited { |
912 | - color:<?php echo $colour2;?>; |
|
912 | + color:<?php echo $colour2; ?>; |
|
913 | 913 | } |
914 | 914 | |
915 | 915 | a:hover { |
@@ -917,7 +917,7 @@ discard block |
||
917 | 917 | } |
918 | 918 | |
919 | 919 | a:active { |
920 | - color:<?php echo $colour2;?>; |
|
920 | + color:<?php echo $colour2; ?>; |
|
921 | 921 | } |
922 | 922 | |
923 | 923 | .comment { |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | * @return string HTML code <table> |
86 | 86 | */ |
87 | 87 | public function prefilledOptionTable(string $attributePrefix) { |
88 | - $retval = "<table id='expandable_$attributePrefix" . "_options'>"; |
|
88 | + $retval = "<table id='expandable_$attributePrefix"."_options'>"; |
|
89 | 89 | |
90 | 90 | $prepopulate = []; |
91 | 91 | foreach ($this->listOfOptions as $existingAttribute) { |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | $prepopulate[] = $existingAttribute; |
94 | 94 | } |
95 | 95 | } |
96 | - if (is_array($prepopulate) && ( count($prepopulate) > 0 || $attributePrefix == "device-specific" || $attributePrefix == "eap-specific" )) { // editing... fill with values |
|
96 | + if (is_array($prepopulate) && (count($prepopulate) > 0 || $attributePrefix == "device-specific" || $attributePrefix == "eap-specific")) { // editing... fill with values |
|
97 | 97 | $retval .= $this->addOptionEdit($attributePrefix, $prepopulate); |
98 | 98 | } else { |
99 | 99 | $retval .= $this->addOptionNew($attributePrefix); |
@@ -125,7 +125,7 @@ discard block |
||
125 | 125 | $optiontypearray = $optioninfo->optionType($option['name']); |
126 | 126 | $loggerInstance = new \core\common\Logging(); |
127 | 127 | $loggerInstance->debug(5, "About to execute optiontext with PREFILL!\n"); |
128 | - $retval .= $this->optiontext([$option['name']], ($optiontypearray["type"] == "file" ? 'ROWID-' . $option['level'] . '-' . $option['row'] : $option['value']), $option['lang']); |
|
128 | + $retval .= $this->optiontext([$option['name']], ($optiontypearray["type"] == "file" ? 'ROWID-'.$option['level'].'-'.$option['row'] : $option['value']), $option['lang']); |
|
129 | 129 | } |
130 | 130 | } |
131 | 131 | return $retval; |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | if (!isset($descriptions[$input])) { |
198 | 198 | return ""; |
199 | 199 | } |
200 | - return "<span class='tooltip' id='S$rowid-tooltip-$input' style='display:" . ($isVisible ? "block" : "none") . "' onclick='alert(\"" . $descriptions[$input] . "\")'><img src='../resources/images/icons/question-mark-icon.png" . "'></span>"; |
|
200 | + return "<span class='tooltip' id='S$rowid-tooltip-$input' style='display:".($isVisible ? "block" : "none")."' onclick='alert(\"".$descriptions[$input]."\")'><img src='../resources/images/icons/question-mark-icon.png"."'></span>"; |
|
201 | 201 | } |
202 | 202 | |
203 | 203 | /** |
@@ -210,18 +210,18 @@ discard block |
||
210 | 210 | */ |
211 | 211 | private function selectElement($rowid, $list) { |
212 | 212 | $jsmagic = "onchange=' |
213 | - if (/#ML#/.test(document.getElementById(\"option-S" . $rowid . "-select\").value)) { |
|
213 | + if (/#ML#/.test(document.getElementById(\"option-S" . $rowid."-select\").value)) { |
|
214 | 214 | document.getElementById(\"S$rowid-input-langselect\").style.display = \"block\"; |
215 | 215 | } else { |
216 | 216 | document.getElementById(\"S$rowid-input-langselect\").style.display = \"none\"; |
217 | 217 | }"; |
218 | 218 | foreach (array_keys(OptionDisplay::HTML_DATATYPE_TEXTS) as $key) { |
219 | - $jsmagic .= "if (/#" . $key . "#/.test(document.getElementById(\"option-S" . $rowid . "-select\").value)) { |
|
220 | - document.getElementById(\"S$rowid-input-file\").style.display = \"" . ($key == \core\Options::TYPECODE_FILE ? "block" : "none") . "\"; |
|
221 | - document.getElementById(\"S$rowid-input-text\").style.display = \"" . ($key == \core\Options::TYPECODE_TEXT ? "block" : "none") . "\"; |
|
222 | - document.getElementById(\"S$rowid-input-string\").style.display = \"" . ($key == \core\Options::TYPECODE_STRING ? "block" : "none") . "\"; |
|
223 | - document.getElementById(\"S$rowid-input-boolean\").style.display = \"" . ($key == \core\Options::TYPECODE_BOOLEAN ? "block" : "none") . "\"; |
|
224 | - document.getElementById(\"S$rowid-input-integer\").style.display = \"" . ($key == \core\Options::TYPECODE_INTEGER ? "block" : "none") . "\"; |
|
219 | + $jsmagic .= "if (/#".$key."#/.test(document.getElementById(\"option-S".$rowid."-select\").value)) { |
|
220 | + document.getElementById(\"S$rowid-input-file\").style.display = \"".($key == \core\Options::TYPECODE_FILE ? "block" : "none")."\"; |
|
221 | + document.getElementById(\"S$rowid-input-text\").style.display = \"".($key == \core\Options::TYPECODE_TEXT ? "block" : "none")."\"; |
|
222 | + document.getElementById(\"S$rowid-input-string\").style.display = \"".($key == \core\Options::TYPECODE_STRING ? "block" : "none")."\"; |
|
223 | + document.getElementById(\"S$rowid-input-boolean\").style.display = \"".($key == \core\Options::TYPECODE_BOOLEAN ? "block" : "none")."\"; |
|
224 | + document.getElementById(\"S$rowid-input-integer\").style.display = \"".($key == \core\Options::TYPECODE_INTEGER ? "block" : "none")."\"; |
|
225 | 225 | } |
226 | 226 | "; |
227 | 227 | // hide all tooltips (each is a <span>, and there are no other <span>s) |
@@ -252,7 +252,7 @@ discard block |
||
252 | 252 | $value = array_shift($list); |
253 | 253 | $listtype = $optioninfo->optionType($value); |
254 | 254 | $retval .= $uiElements->displayName($value); |
255 | - $retval .= "<input type='hidden' name='option[S$rowid]' value='$value#" . $listtype["type"] . "#" . $listtype["flag"] . "#'/>"; |
|
255 | + $retval .= "<input type='hidden' name='option[S$rowid]' value='$value#".$listtype["type"]."#".$listtype["flag"]."#'/>"; |
|
256 | 256 | $activelisttype = $listtype; |
257 | 257 | $tooltips = $this->tooltip($rowid, $value, TRUE); |
258 | 258 | break; |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | $retval .= "<select id='option-S$rowid-select' name='option[S$rowid]' $jsmagic>"; |
261 | 261 | foreach ($list as $value) { |
262 | 262 | $listtype = $optioninfo->optionType($value); |
263 | - $retval .= "<option id='option-S$rowid-v-$value' value='$value#" . $listtype["type"] . "#" . $listtype["flag"] . "#' "; |
|
263 | + $retval .= "<option id='option-S$rowid-v-$value' value='$value#".$listtype["type"]."#".$listtype["flag"]."#' "; |
|
264 | 264 | if ($iterator == $this->optionIterator) { |
265 | 265 | $retval .= "selected='selected'"; |
266 | 266 | $activelisttype = $listtype; |
@@ -268,7 +268,7 @@ discard block |
||
268 | 268 | } else { |
269 | 269 | $tooltips .= $this->tooltip($rowid, $value, FALSE); |
270 | 270 | } |
271 | - $retval .= ">" . $uiElements->displayName($value) . "</option>"; |
|
271 | + $retval .= ">".$uiElements->displayName($value)."</option>"; |
|
272 | 272 | $iterator++; |
273 | 273 | } |
274 | 274 | |
@@ -293,9 +293,9 @@ discard block |
||
293 | 293 | */ |
294 | 294 | private function selectLanguage($rowid, $makeVisible) { |
295 | 295 | \core\common\Entity::intoThePotatoes(); |
296 | - $retval = "<select style='display:" . ($makeVisible ? "block" : "none") . "' name='value[S$rowid-lang]' id='S" . $rowid . "-input-langselect'> |
|
297 | - <option value='' name='select_language' selected>" . _("select language") . "</option> |
|
298 | - <option value='C' name='all_languages'>" . _("default/other languages") . "</option>"; |
|
296 | + $retval = "<select style='display:".($makeVisible ? "block" : "none")."' name='value[S$rowid-lang]' id='S".$rowid."-input-langselect'> |
|
297 | + <option value='' name='select_language' selected>" . _("select language")."</option> |
|
298 | + <option value='C' name='all_languages'>" . _("default/other languages")."</option>"; |
|
299 | 299 | foreach (\config\Main::LANGUAGES as $langindex => $possibleLang) { |
300 | 300 | $thislang = $possibleLang['display']; |
301 | 301 | $retval .= "<option value='$langindex' name='$langindex'>$thislang</option>"; |
@@ -323,7 +323,7 @@ discard block |
||
323 | 323 | private function inputFields($rowid, $activetype) { |
324 | 324 | $retval = ""; |
325 | 325 | foreach (OptionDisplay::HTML_DATATYPE_TEXTS as $key => $type) { |
326 | - $retval .= "<" . $type['html'] . " style='display:" . ($activetype['type'] == $key ? "block" : "none") . "' name='value[S$rowid-$key]' id='S" . $rowid . "-input-" . $key . "'" . $type['tail'] . ">"; |
|
326 | + $retval .= "<".$type['html']." style='display:".($activetype['type'] == $key ? "block" : "none")."' name='value[S$rowid-$key]' id='S".$rowid."-input-".$key."'".$type['tail'].">"; |
|
327 | 327 | } |
328 | 328 | return $retval; |
329 | 329 | } |
@@ -338,11 +338,11 @@ discard block |
||
338 | 338 | private function noPrefillText(int $rowid, array $list) { |
339 | 339 | // first column: the <select> element with the names of options and their field-toggling JS magic |
340 | 340 | $selectorInfo = $this->selectElement($rowid, $list); |
341 | - $retval = "<td>" . $selectorInfo["TEXT"] . "</td>"; |
|
341 | + $retval = "<td>".$selectorInfo["TEXT"]."</td>"; |
|
342 | 342 | // second column: the <select> element for language selection - only visible if the active option is multi-lang |
343 | - $retval .= "<td>" . $this->selectLanguage($rowid, $selectorInfo['ACTIVE']['flag'] == "ML") . "</td>"; |
|
343 | + $retval .= "<td>".$this->selectLanguage($rowid, $selectorInfo['ACTIVE']['flag'] == "ML")."</td>"; |
|
344 | 344 | // third column: the actual input fields; the data type of the active option is visible, all others hidden |
345 | - $retval .= "<td>" . $this->inputFields($rowid, $selectorInfo['ACTIVE']) . "</td>"; |
|
345 | + $retval .= "<td>".$this->inputFields($rowid, $selectorInfo['ACTIVE'])."</td>"; |
|
346 | 346 | return $retval; |
347 | 347 | } |
348 | 348 | |
@@ -365,20 +365,20 @@ discard block |
||
365 | 365 | $retval .= "<td>"; |
366 | 366 | $uiElements = new UIElements(); |
367 | 367 | $listtype = $optioninfo->optionType($optionName); |
368 | - $retval .= "<span style='display:flex;'>" . $uiElements->displayName($optionName); |
|
369 | - $retval .= $this->tooltip($rowid, $optionName, TRUE) . "</span>"; |
|
370 | - $retval .= "<input type='hidden' id='option-S$rowid-select' name='option[S$rowid]' value='$optionName#" . $listtype["type"] . "#" . $listtype["flag"] . "#' ></td>"; |
|
368 | + $retval .= "<span style='display:flex;'>".$uiElements->displayName($optionName); |
|
369 | + $retval .= $this->tooltip($rowid, $optionName, TRUE)."</span>"; |
|
370 | + $retval .= "<input type='hidden' id='option-S$rowid-select' name='option[S$rowid]' value='$optionName#".$listtype["type"]."#".$listtype["flag"]."#' ></td>"; |
|
371 | 371 | |
372 | 372 | // language tag if any |
373 | 373 | $retval .= "<td>"; |
374 | 374 | if ($listtype["flag"] == "ML") { |
375 | 375 | |
376 | - $language = "(" . strtoupper($optionLang) . ")"; |
|
376 | + $language = "(".strtoupper($optionLang).")"; |
|
377 | 377 | if ($optionLang == 'C') { |
378 | 378 | $language = _("(default/other languages)"); |
379 | 379 | } |
380 | 380 | $retval .= $language; |
381 | - $retval .= "<input type='hidden' name='value[S$rowid-lang]' id='S" . $rowid . "-input-langselect' value='" . $optionLang . "' style='display:block'>"; |
|
381 | + $retval .= "<input type='hidden' name='value[S$rowid-lang]' id='S".$rowid."-input-langselect' value='".$optionLang."' style='display:block'>"; |
|
382 | 382 | } |
383 | 383 | $retval .= "</td>"; |
384 | 384 | // attribute content |
@@ -388,12 +388,12 @@ discard block |
||
388 | 388 | case \core\Options::TYPECODE_COORDINATES: |
389 | 389 | $this->allLocationCount = $this->allLocationCount + 1; |
390 | 390 | // display of the locations varies by map provider |
391 | - $classname = "\web\lib\admin\Map" . \config\ConfAssistant::MAPPROVIDER['PROVIDER']; |
|
391 | + $classname = "\web\lib\admin\Map".\config\ConfAssistant::MAPPROVIDER['PROVIDER']; |
|
392 | 392 | $link = $classname::optionListDisplayCode($optionValue, $this->allLocationCount); |
393 | - $retval .= "<input readonly style='display:none' type='text' name='value[S$rowid-" . \core\Options::TYPECODE_TEXT . "]' id='S$rowid-input-text' value='$optionValue'>$link"; |
|
393 | + $retval .= "<input readonly style='display:none' type='text' name='value[S$rowid-".\core\Options::TYPECODE_TEXT."]' id='S$rowid-input-text' value='$optionValue'>$link"; |
|
394 | 394 | break; |
395 | 395 | case \core\Options::TYPECODE_FILE: |
396 | - $retval .= "<input readonly type='text' name='value[S$rowid-" . \core\Options::TYPECODE_STRING . "]' id='S" . $rowid . "-input-string' style='display:none' value='" . urlencode($optionValue) . "'>"; |
|
396 | + $retval .= "<input readonly type='text' name='value[S$rowid-".\core\Options::TYPECODE_STRING."]' id='S".$rowid."-input-string' style='display:none' value='".urlencode($optionValue)."'>"; |
|
397 | 397 | $uiElements = new UIElements(); |
398 | 398 | switch ($optionName) { |
399 | 399 | case "eap:ca_file": |
@@ -423,7 +423,7 @@ discard block |
||
423 | 423 | if ($listtype['type'] == \core\Options::TYPECODE_BOOLEAN) {// only modify in this one case |
424 | 424 | $displayedVariant = ($optionValue == "on" ? _("on") : _("off")); |
425 | 425 | } |
426 | - $retval .= "<strong>$displayedVariant</strong><input type='hidden' name='value[S$rowid-" . $listtype['type'] . "]' id='S" . $rowid . "-input-" . $listtype["type"] . "' value=\"" . htmlspecialchars($optionValue) . "\" style='display:block'>"; |
|
426 | + $retval .= "<strong>$displayedVariant</strong><input type='hidden' name='value[S$rowid-".$listtype['type']."]' id='S".$rowid."-input-".$listtype["type"]."' value=\"".htmlspecialchars($optionValue)."\" style='display:block'>"; |
|
427 | 427 | break; |
428 | 428 | default: |
429 | 429 | // this should never happen! |
@@ -468,10 +468,10 @@ discard block |
||
468 | 468 | <td> |
469 | 469 | <button type='button' class='delete' onclick='"; |
470 | 470 | if ($prefillValue !== NULL && $item == "general:geo_coordinates") { |
471 | - $funcname = "Map" . \config\ConfAssistant::MAPPROVIDER['PROVIDER'] . 'DeleteCoord'; |
|
472 | - $retval .= 'if (typeof ' . $funcname . ' === "function") { ' . $funcname . '(' . $this->allLocationCount . '); } '; |
|
471 | + $funcname = "Map".\config\ConfAssistant::MAPPROVIDER['PROVIDER'].'DeleteCoord'; |
|
472 | + $retval .= 'if (typeof '.$funcname.' === "function") { '.$funcname.'('.$this->allLocationCount.'); } '; |
|
473 | 473 | } |
474 | - $retval .= 'deleteOption("option-S' . $rowid . '")'; |
|
474 | + $retval .= 'deleteOption("option-S'.$rowid.'")'; |
|
475 | 475 | $retval .= "'>-</button> |
476 | 476 | </td> |
477 | 477 | </tr>"; |