@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | */ |
28 | 28 | function my_nonce($optSalt = '') { |
29 | 29 | $remote = filter_input(INPUT_SERVER, 'REMOTE_ADDR'); |
30 | - return hash_hmac('sha256', session_id() . $optSalt, date("YmdG") . '1qaz2wsx3edc!QAZ@WSX#EDC' . $remote); |
|
30 | + return hash_hmac('sha256', session_id().$optSalt, date("YmdG").'1qaz2wsx3edc!QAZ@WSX#EDC'.$remote); |
|
31 | 31 | } |
32 | 32 | error_reporting(E_ALL | E_STRICT); |
33 | 33 | $Gui->defaultPagePrelude(); |
@@ -51,16 +51,16 @@ discard block |
||
51 | 51 | <?php |
52 | 52 | $admin = filter_input(INPUT_GET, 'admin', FILTER_VALIDATE_INT); |
53 | 53 | $profile_list_size = 1; |
54 | -require_once dirname(__DIR__) . '/Divs.php'; |
|
54 | +require_once dirname(__DIR__).'/Divs.php'; |
|
55 | 55 | $divs = new Divs($Gui); |
56 | 56 | $visibility = 'index'; |
57 | 57 | $operatingSystem = $Gui->detectOS(); |
58 | 58 | $Gui->loggerInstance->debug(4, $operatingSystem); |
59 | 59 | $uiElements = new web\lib\admin\UIElements(); |
60 | 60 | if ($operatingSystem) { |
61 | - print "recognisedOS = '" . $operatingSystem['device'] . "';\n"; |
|
61 | + print "recognisedOS = '".$operatingSystem['device']."';\n"; |
|
62 | 62 | } |
63 | -require dirname(__DIR__) . '/user/js/cat_js.php'; |
|
63 | +require dirname(__DIR__).'/user/js/cat_js.php'; |
|
64 | 64 | ?> |
65 | 65 | |
66 | 66 | </script> |
@@ -93,9 +93,9 @@ discard block |
||
93 | 93 | <?php echo $divs->div_pagetitle(_("Diagnostics site"), ""); ?> |
94 | 94 | <div id="user_info" style='padding-top: 10px;'> |
95 | 95 | <div id='diagnostic_choice'> |
96 | - <?php echo _("The diagnostics system will do its best to identify and resolve your problems!") . ' ' . _("Please help the system by answering the questions as precisely as possible.") . "<br/>" . _("Are you a") . ' '; ?> |
|
97 | - <input type='radio' name='diagnostic_usertype' value='0'><?php echo _("end-user") . ' ' . _("or"); ?> |
|
98 | - <input type='radio' name='diagnostic_usertype' value='1' <?php if ($admin == 1) { echo " checked"; } ?> > <?php echo _("eduroam administrator") .'?'; ?> |
|
96 | + <?php echo _("The diagnostics system will do its best to identify and resolve your problems!").' '._("Please help the system by answering the questions as precisely as possible.")."<br/>"._("Are you a").' '; ?> |
|
97 | + <input type='radio' name='diagnostic_usertype' value='0'><?php echo _("end-user").' '._("or"); ?> |
|
98 | + <input type='radio' name='diagnostic_usertype' value='1' <?php if ($admin == 1) { echo " checked"; } ?> > <?php echo _("eduroam administrator").'?'; ?> |
|
99 | 99 | </div> |
100 | 100 | <div id='diagnostic_enduser' style='display: none;'> |
101 | 101 | <h2><?php echo _("Tools for End Users"); ?></h2> |
@@ -105,24 +105,24 @@ discard block |
||
105 | 105 | ?> |
106 | 106 | </p> |
107 | 107 | <?php |
108 | - echo '<div id="before_stage_1"><h3>' . _("The system needs some information on your home institution - issuer of your account") . '</h3>'; |
|
108 | + echo '<div id="before_stage_1"><h3>'._("The system needs some information on your home institution - issuer of your account").'</h3>'; |
|
109 | 109 | echo _("What is the realm part of your user account (the part behind the @ of 'your.username@<b>realm.tld</b>):"); |
110 | 110 | ?> |
111 | 111 | <input type='text' name='user_realm' id='user_realm' value=''> |
112 | 112 | <?php |
113 | - echo '<div id="realm_by_select"><br/>' . _("alternatively") . '<br/>'; |
|
114 | - echo _("You can select your home institution from the following list") . '<br/>'; |
|
113 | + echo '<div id="realm_by_select"><br/>'._("alternatively").'<br/>'; |
|
114 | + echo _("You can select your home institution from the following list").'<br/>'; |
|
115 | 115 | echo '<div id="select_idp_country"><a href="" id="idp_countries_list">'; |
116 | - echo '<span id="realmselect">' . _("Click to select your country/region and organisation") . '</span></a></div>'; |
|
116 | + echo '<span id="realmselect">'._("Click to select your country/region and organisation").'</span></a></div>'; |
|
117 | 117 | ?> |
118 | 118 | <div id="select_idp_area" style="display:none;"> |
119 | 119 | </div> |
120 | 120 | </div> |
121 | 121 | <div id="position_info"> |
122 | 122 | <?php |
123 | - echo '<h3>' . _("Optionally, to improve tests, you can provide information on your current location") . '</h3>'; |
|
123 | + echo '<h3>'._("Optionally, to improve tests, you can provide information on your current location").'</h3>'; |
|
124 | 124 | echo '<div id="select_sp_country"><a href="" id="sp_countries_list">'; |
125 | - echo '<span id="spselect">' . _("Click to select a location in which you have an eduroam problem") . '</span></a></div>'; |
|
125 | + echo '<span id="spselect">'._("Click to select a location in which you have an eduroam problem").'</span></a></div>'; |
|
126 | 126 | ?> |
127 | 127 | <div id="select_sp_area" style="display:none;"> |
128 | 128 | </div> |
@@ -155,9 +155,9 @@ discard block |
||
155 | 155 | echo 'none'; |
156 | 156 | } |
157 | 157 | echo ";'>"; |
158 | - echo '<h3>' . _("Which problem are you reporting?") . '</h3>'; |
|
158 | + echo '<h3>'._("Which problem are you reporting?").'</h3>'; |
|
159 | 159 | echo '<input type="radio" name="problem_type" value="1">'; |
160 | - echo _("SP contacting IdP due to technical problems or abuse") . '<br>'; |
|
160 | + echo _("SP contacting IdP due to technical problems or abuse").'<br>'; |
|
161 | 161 | echo '<input type="radio" name="problem_type" value="2">'; |
162 | 162 | echo _("IdP contacting SP due to technical problems"); |
163 | 163 | echo "<div id='idp_contact_area'></div>"; |
@@ -166,9 +166,9 @@ discard block |
||
166 | 166 | echo "</div>"; |
167 | 167 | } else { |
168 | 168 | echo "0\">"; |
169 | - echo _("This service is for authenticated admins only.") . '<br>'; |
|
170 | - echo "<a href=\"diag.php?admin=1\">" . |
|
171 | - _("eduroam® admin access is needed") . "</a>"; |
|
169 | + echo _("This service is for authenticated admins only.").'<br>'; |
|
170 | + echo "<a href=\"diag.php?admin=1\">". |
|
171 | + _("eduroam® admin access is needed")."</a>"; |
|
172 | 172 | } |
173 | 173 | ?> |
174 | 174 | </div> |
@@ -192,7 +192,7 @@ discard block |
||
192 | 192 | if (type === 'idp' || type === 'sp') { |
193 | 193 | shtml = '<table><tbody><tr id="row_'+type+'_country"></tr>'; |
194 | 194 | shtml = shtml + '<tr id="row_'+type+'_institution" style="visibility: collapse;">'; |
195 | - shtml = shtml + '<td>' + <?php echo '"' . _("Select institiution:") . '"'; ?> + '</td><td></td></tr>'; |
|
195 | + shtml = shtml + '<td>' + <?php echo '"'._("Select institiution:").'"'; ?> + '</td><td></td></tr>'; |
|
196 | 196 | if (type === 'idp') { |
197 | 197 | shtml = shtml + '<tr id="row_idp_realm"></tr>'; |
198 | 198 | } |
@@ -218,7 +218,7 @@ discard block |
||
218 | 218 | var options = ''; |
219 | 219 | var selecthead = ''; |
220 | 220 | if (type1 === 'sp' || type1 === 'idp') { |
221 | - selecthead = <?php echo '"<td>' . _("Select country or region:") . ' </td>"'; ?>; |
|
221 | + selecthead = <?php echo '"<td>'._("Select country or region:").' </td>"'; ?>; |
|
222 | 222 | selecthead = selecthead + '<td>\n'; |
223 | 223 | } |
224 | 224 | var select = '<select id="' + type1 + '_country" name="' + type1 + '_country" style="margin-left:0px; width:400px;">'; |
@@ -226,7 +226,7 @@ discard block |
||
226 | 226 | options = ($('#'+type2+'_country').html()); |
227 | 227 | countryAddSelect(selecthead, select + options + '</select>', type1); |
228 | 228 | } else { |
229 | - var comment = <?php echo '"<br><br>' . _("Fetching country/region list") . '..."'; ?>; |
|
229 | + var comment = <?php echo '"<br><br>'._("Fetching country/region list").'..."'; ?>; |
|
230 | 230 | inProgress(1, comment); |
231 | 231 | $.ajax({ |
232 | 232 | url: "findRealm.php", |
@@ -260,7 +260,7 @@ discard block |
||
260 | 260 | return false; |
261 | 261 | } |
262 | 262 | function testSociopath(realm, answer) { |
263 | - var comment = <?php echo '"' . _("Testing realm") . '..."'; ?>; |
|
263 | + var comment = <?php echo '"'._("Testing realm").'..."'; ?>; |
|
264 | 264 | inProgress(1, comment); |
265 | 265 | if ($('#tested_realm').length == 0) { |
266 | 266 | $('<input>').attr({ |
@@ -285,9 +285,9 @@ discard block |
||
285 | 285 | query = '<input type="hidden" id="tested_realm" value="' + realm + '">'; |
286 | 286 | } |
287 | 287 | query = query + '<div id="current_query">'+data['TEXT']+'</div>'; |
288 | - query = query + '<div><button id="answer_yes">' + <?php echo '"' . _("Yes") . '"'; ?> + '</button>'; |
|
289 | - query = query + '<button style="margin-left:20px;" id="answer_no">' + <?php echo '"' . _("No") . '"'; ?> + '</button>'; |
|
290 | - query = query + '<button style="margin-left:20px;" id="answer_noidea">' + <?php echo '"' . _("I don't know") . '"'; ?> + '</button></div>'; |
|
288 | + query = query + '<div><button id="answer_yes">' + <?php echo '"'._("Yes").'"'; ?> + '</button>'; |
|
289 | + query = query + '<button style="margin-left:20px;" id="answer_no">' + <?php echo '"'._("No").'"'; ?> + '</button>'; |
|
290 | + query = query + '<button style="margin-left:20px;" id="answer_noidea">' + <?php echo '"'._("I don't know").'"'; ?> + '</button></div>'; |
|
291 | 291 | $('#sociopath_queries').html(query); |
292 | 292 | $('#sociopath_query_area').show(); |
293 | 293 | } |
@@ -318,55 +318,55 @@ discard block |
||
318 | 318 | }); |
319 | 319 | } |
320 | 320 | function finalVerdict(realm, verdict) { |
321 | - var title = <?php echo '"' . _("Diagnostic tests results for selected realm") . '"'; ?>; |
|
321 | + var title = <?php echo '"'._("Diagnostic tests results for selected realm").'"'; ?>; |
|
322 | 322 | result = '<div class="padding">'; |
323 | 323 | result = result + '<div><h3>'; |
324 | - result = result + <?php echo '"' . _("The result for tested realm:") . ' "'; ?> + realm; |
|
324 | + result = result + <?php echo '"'._("The result for tested realm:").' "'; ?> + realm; |
|
325 | 325 | result = result + '</h3></p><div style="padding: 5px;"><div style="padding: 0px;">'; |
326 | - result = result + <?php echo '"' . _("The system identified") . '" '; ?> + ' '; |
|
326 | + result = result + <?php echo '"'._("The system identified").'" '; ?> + ' '; |
|
327 | 327 | result = result + Object.keys(verdict).length + ' '; |
328 | - result = result + <?php echo '"' . _("suspected areas which potentially can cause a problem.") . '"'; ?> + '<br>'; |
|
329 | - result = result + <?php echo '"' . _("Next to the problem description we show a speculated probability of this event.") . '"'; ?>; |
|
328 | + result = result + <?php echo '"'._("suspected areas which potentially can cause a problem.").'"'; ?> + '<br>'; |
|
329 | + result = result + <?php echo '"'._("Next to the problem description we show a speculated probability of this event.").'"'; ?>; |
|
330 | 330 | result = result + '</div><div style="padding: 5px;"><table>'; |
331 | 331 | k = 1; |
332 | 332 | for (key in verdict) { |
333 | 333 | result = result + '<tr><td>' + k + '.</td>'; |
334 | 334 | k = k + 1; |
335 | 335 | if (key === 'INFRA_DEVICE') { |
336 | - result = result + '<td>' + <?php echo '"' . _("Your device configuration is broken") . '"'; ?> + '</td>'; |
|
336 | + result = result + '<td>' + <?php echo '"'._("Your device configuration is broken").'"'; ?> + '</td>'; |
|
337 | 337 | } |
338 | 338 | if (key === 'INFRA_SP_80211') { |
339 | - result = result + '<td>' + <?php echo '"' . _("The Wi-Fi network in your vicinity has quality issues") . '"'; ?> + '</td>'; |
|
339 | + result = result + '<td>' + <?php echo '"'._("The Wi-Fi network in your vicinity has quality issues").'"'; ?> + '</td>'; |
|
340 | 340 | } |
341 | 341 | if (key === 'INFRA_SP_LAN') { |
342 | - result = result + '<td>' + <?php echo '"' . _("The network environment around you is broken") . '"'; ?> + '</td>'; |
|
342 | + result = result + '<td>' + <?php echo '"'._("The network environment around you is broken").'"'; ?> + '</td>'; |
|
343 | 343 | } |
344 | 344 | if (key === 'INFRA_SP_RADIUS') { |
345 | - result = result + '<td>' + <?php echo '"' . _("The RADIUS server of your service provider is the source of the problem") . '"'; ?> + '</td>'; |
|
345 | + result = result + '<td>' + <?php echo '"'._("The RADIUS server of your service provider is the source of the problem").'"'; ?> + '</td>'; |
|
346 | 346 | } |
347 | 347 | if (key === 'INFRA_IDP_AUTHBACKEND') { |
348 | - result = result + '<td>' + <?php echo '"' . _("The RADIUS server in your home institution is currently unable to authenticate you") . '"'; ?> + '</td>'; |
|
348 | + result = result + '<td>' + <?php echo '"'._("The RADIUS server in your home institution is currently unable to authenticate you").'"'; ?> + '</td>'; |
|
349 | 349 | } |
350 | 350 | if (key === 'INFRA_NRO_SP') { |
351 | - result = result + '<td>' + <?php echo '"' . _("The national server in the country/region you are visiting is not functioning correctly") . '"'; ?> + '</td>'; |
|
351 | + result = result + '<td>' + <?php echo '"'._("The national server in the country/region you are visiting is not functioning correctly").'"'; ?> + '</td>'; |
|
352 | 352 | } |
353 | 353 | if (key === 'INFRA_LINK_ETLR_NRO_SP') { |
354 | - result = result + '<td>' + <?php echo '"' . _("The link between the national server of the country/region you are visiting and the top-level server is broken") . '"'; ?> + '</td>'; |
|
354 | + result = result + '<td>' + <?php echo '"'._("The link between the national server of the country/region you are visiting and the top-level server is broken").'"'; ?> + '</td>'; |
|
355 | 355 | } |
356 | 356 | if (key === 'INFRA_LINK_ETLR_NRO_IdP') { |
357 | - result = result + '<td>' + <?php echo '"' . _("The link between the national server of your home country/region and the top-level server is broken") . '"'; ?> + '</td>'; |
|
357 | + result = result + '<td>' + <?php echo '"'._("The link between the national server of your home country/region and the top-level server is broken").'"'; ?> + '</td>'; |
|
358 | 358 | } |
359 | 359 | if (key === 'INFRA_ETLR') { |
360 | - result = result + '<td>' + <?php echo '"' . _("The communication to the top-level server is down") . '"'; ?> + '</td>'; |
|
360 | + result = result + '<td>' + <?php echo '"'._("The communication to the top-level server is down").'"'; ?> + '</td>'; |
|
361 | 361 | } |
362 | 362 | if (key === 'INFRA_NRO_IdP') { |
363 | - result = result + '<td>' + <?php echo '"' . _("The national server in your home country/region is not functioning properly.") . '"'; ?> + '</td>'; |
|
363 | + result = result + '<td>' + <?php echo '"'._("The national server in your home country/region is not functioning properly.").'"'; ?> + '</td>'; |
|
364 | 364 | } |
365 | 365 | if (key === 'INFRA_IdP_RADIUS') { |
366 | - result = result + '<td>' + <?php echo '"' . _("The RADIUS server of your home institution is the source of the problem") . '"'; ?> + '</td>'; |
|
366 | + result = result + '<td>' + <?php echo '"'._("The RADIUS server of your home institution is the source of the problem").'"'; ?> + '</td>'; |
|
367 | 367 | } |
368 | 368 | if (key === 'INFRA_NONEXISTENTREALM') { |
369 | - result = result + '<td>' + <?php echo '"' . _("This realm does not exist") . '"'; ?> + '</td>'; |
|
369 | + result = result + '<td>' + <?php echo '"'._("This realm does not exist").'"'; ?> + '</td>'; |
|
370 | 370 | } |
371 | 371 | result = result + '<td style="padding-left: 5px;">' + (verdict[key] * 100).toFixed(2) + "%</td></tr>"; |
372 | 372 | } |
@@ -478,7 +478,7 @@ discard block |
||
478 | 478 | return false; |
479 | 479 | }); |
480 | 480 | $(document).on('change', '#idp_country, #sp_country, #asp_country' , function() { |
481 | - var comment = <?php echo '"' . _("Fetching institutions list") . '..."'; ?>; |
|
481 | + var comment = <?php echo '"'._("Fetching institutions list").'..."'; ?>; |
|
482 | 482 | var id = $(this).attr('id'); |
483 | 483 | var k = id.indexOf('_'); |
484 | 484 | var type = id.substr(0,k); |
@@ -496,7 +496,7 @@ discard block |
||
496 | 496 | var shtml = ''; |
497 | 497 | var select = ''; |
498 | 498 | if (type !== 'asp') { |
499 | - shtml = <?php echo '"<td>' . _("Select institution:") . '</td><td>"'; ?>; |
|
499 | + shtml = <?php echo '"<td>'._("Select institution:").'</td><td>"'; ?>; |
|
500 | 500 | } |
501 | 501 | select = '<select id="' + type + '_inst" name="' + type + '_inst" style="margin-left:0px; width:400px;"><option value=""></option>'; |
502 | 502 | for (var i in institutions) { |
@@ -536,7 +536,7 @@ discard block |
||
536 | 536 | $('#start_test_area').hide(); |
537 | 537 | return false; |
538 | 538 | } |
539 | - var comment = <?php echo '"' . _("Fetching realms list") . '..."'; ?>; |
|
539 | + var comment = <?php echo '"'._("Fetching realms list").'..."'; ?>; |
|
540 | 540 | inProgress(1, comment); |
541 | 541 | $.ajax({ |
542 | 542 | url: "findRealm.php", |
@@ -548,7 +548,7 @@ discard block |
||
548 | 548 | var realms = data.realms; |
549 | 549 | var realmselect = ''; |
550 | 550 | if (realms.length > 1) { |
551 | - realmselect = <?php echo '"<td>' . _("Check realm(s):") . '</td>"'; ?>; |
|
551 | + realmselect = <?php echo '"<td>'._("Check realm(s):").'</td>"'; ?>; |
|
552 | 552 | realmselect = realmselect + '<td>' + "<span style='margin-left: 10px'>"; |
553 | 553 | for (var i in realms) { |
554 | 554 | realmselect = realmselect + '<input type="radio" name="realm" '; |
@@ -560,7 +560,7 @@ discard block |
||
560 | 560 | } |
561 | 561 | realmselect = realmselect + '</span></td>'; |
562 | 562 | } else { |
563 | - realmselect = <?php echo '"<td>' . _("Realm:") . '</td>"'; ?>; |
|
563 | + realmselect = <?php echo '"<td>'._("Realm:").'</td>"'; ?>; |
|
564 | 564 | realmselect = realmselect + '<td>' + "<span style='margin-left: 10px'>"; |
565 | 565 | realmselect = realmselect + realms[0] + '</span>'; |
566 | 566 | realmselect = realmselect + '<input type="hidden" name="realm" value="' + realms[0] + '">'; |
@@ -615,7 +615,7 @@ discard block |
||
615 | 615 | }); |
616 | 616 | t = 1; |
617 | 617 | } |
618 | - var comment = <?php echo '"' . _("Running realm tests") . '..."'; ?>; |
|
618 | + var comment = <?php echo '"'._("Running realm tests").'..."'; ?>; |
|
619 | 619 | inProgress(1, comment); |
620 | 620 | /*waiting(comment);*/ |
621 | 621 | $.ajax({ |
@@ -659,7 +659,7 @@ discard block |
||
659 | 659 | } |
660 | 660 | }); |
661 | 661 | $('#sp_questions > tbody').append('<tr class="error_row"><td>' + |
662 | - <?php echo '"' . _("Realm is not registered with the eduroam database:") . '"'; ?> + |
|
662 | + <?php echo '"'._("Realm is not registered with the eduroam database:").'"'; ?> + |
|
663 | 663 | '</td><td>' + realm + '</td></tr>'); |
664 | 664 | $('#admin_realm').val(''); |
665 | 665 | } |
@@ -683,7 +683,7 @@ discard block |
||
683 | 683 | testSociopath('', answer); |
684 | 684 | }); |
685 | 685 | $('#realmtest').click(function(event){ |
686 | - var comment = <?php echo '"<br><br>' . _("Running realm tests") . '..."'; ?>; |
|
686 | + var comment = <?php echo '"<br><br>'._("Running realm tests").'..."'; ?>; |
|
687 | 687 | inProgress(1, comment); |
688 | 688 | $('#start_test_area').hide(); |
689 | 689 | if ($('#select_sp_area').is(':hidden')) { |
@@ -727,13 +727,13 @@ discard block |
||
727 | 727 | reset_footer(); |
728 | 728 | testSociopath(realm, 0); |
729 | 729 | } else { |
730 | - var title = <?php echo '"' . _("Diagnostics results for selected realms") . '"'; ?>; |
|
731 | - result = '<div class="padding"><h3>' + <?php echo '"' . _("An unknown problem occured") . '"'; ?>; |
|
730 | + var title = <?php echo '"'._("Diagnostics results for selected realms").'"'; ?>; |
|
731 | + result = '<div class="padding"><h3>' + <?php echo '"'._("An unknown problem occured").'"'; ?>; |
|
732 | 732 | result = result + '</h3>' |
733 | 733 | if (r.length == 1) { |
734 | - result = result + <?php echo '"' . _("This test includes checking of the following realm") . '"'; ?>; |
|
734 | + result = result + <?php echo '"'._("This test includes checking of the following realm").'"'; ?>; |
|
735 | 735 | } else { |
736 | - result = result + <?php echo '"' . _("This test includes checking of the following realms") . '"'; ?>; |
|
736 | + result = result + <?php echo '"'._("This test includes checking of the following realms").'"'; ?>; |
|
737 | 737 | } |
738 | 738 | result = result + ': ' |
739 | 739 | for (var i=0; i < r.length; i++) { |
@@ -743,7 +743,7 @@ discard block |
||
743 | 743 | result = result + r[i]; |
744 | 744 | } |
745 | 745 | result = result + '.<br>'; |
746 | - result = result + <?php echo '"' . _("You should report this to") . '"'; ?> + ' <a href="mailto:[email protected]">[email protected]</a>'; |
|
746 | + result = result + <?php echo '"'._("You should report this to").'"'; ?> + ' <a href="mailto:[email protected]">[email protected]</a>'; |
|
747 | 747 | result = result + '</div>'; |
748 | 748 | $('#after_stage_1').hide(); |
749 | 749 | $('#before_stage_1').show(); |
@@ -796,7 +796,7 @@ discard block |
||
796 | 796 | }); |
797 | 797 | }); |
798 | 798 | }); |
799 | - var comment = <?php echo '"' . _("Running realm tests") . '..."'; ?>; |
|
799 | + var comment = <?php echo '"'._("Running realm tests").'..."'; ?>; |
|
800 | 800 | inProgress(1, comment); |
801 | 801 | $.ajax({ |
802 | 802 | url: "findRealm.php", |
@@ -867,29 +867,29 @@ discard block |
||
867 | 867 | success:function(data) { |
868 | 868 | if (data.status === 1) { |
869 | 869 | var result = ''; |
870 | - var title = <?php echo '"' . _("eduroam admin report submission") . '"'; ?>; |
|
870 | + var title = <?php echo '"'._("eduroam admin report submission").'"'; ?>; |
|
871 | 871 | result = '<div class="padding">'; |
872 | 872 | if (type == 'idp_send') { |
873 | - result = result + '<h3>'+ <?php echo '"' . _("SP contacting IdP due to technical problems or abuse") . '"'; ?> + '</h3>'; |
|
873 | + result = result + '<h3>'+ <?php echo '"'._("SP contacting IdP due to technical problems or abuse").'"'; ?> + '</h3>'; |
|
874 | 874 | result = result + '<table>'; |
875 | - result = result + '<tr><td>' + <?php echo '"' . _("Reason") . '"'; ?> + '</td><td>' + data.reason + '</td></tr>'; |
|
876 | - result = result + '<tr><td>' + <?php echo '"' . _("SP email") . '"'; ?> + '</td><td>' + data.email + '</td></tr>'; |
|
877 | - result = result + '<tr><td>' + <?php echo '"' . _("IdP email(s)") . '"'; ?> + '</td><td>' + data.idpcontact + '</td></tr>'; |
|
878 | - result = result + '<tr><td>' + <?php echo '"' . _("Event's timestamp") . '"'; ?> + '</td><td>' + data.timestamp + '</td></tr>'; |
|
879 | - result = result + '<tr><td>' + <?php echo '"' . _("Calling-Station-Id") . '"'; ?> + '</td><td>' + data.mac + '</td></tr>'; |
|
880 | - result = result + '<tr><td>' + <?php echo '"' . _("Additional description") . '"'; ?> +'</td><td>' + data.freetext + '</td></tr>'; |
|
875 | + result = result + '<tr><td>' + <?php echo '"'._("Reason").'"'; ?> + '</td><td>' + data.reason + '</td></tr>'; |
|
876 | + result = result + '<tr><td>' + <?php echo '"'._("SP email").'"'; ?> + '</td><td>' + data.email + '</td></tr>'; |
|
877 | + result = result + '<tr><td>' + <?php echo '"'._("IdP email(s)").'"'; ?> + '</td><td>' + data.idpcontact + '</td></tr>'; |
|
878 | + result = result + '<tr><td>' + <?php echo '"'._("Event's timestamp").'"'; ?> + '</td><td>' + data.timestamp + '</td></tr>'; |
|
879 | + result = result + '<tr><td>' + <?php echo '"'._("Calling-Station-Id").'"'; ?> + '</td><td>' + data.mac + '</td></tr>'; |
|
880 | + result = result + '<tr><td>' + <?php echo '"'._("Additional description").'"'; ?> +'</td><td>' + data.freetext + '</td></tr>'; |
|
881 | 881 | } |
882 | 882 | if (type == 'sp_send') { |
883 | - result = result + '<h3>'+ <?php echo '"' . _("IdP contacting SP due to technical problems or abuse") . '"'; ?> + '</h3>'; |
|
883 | + result = result + '<h3>'+ <?php echo '"'._("IdP contacting SP due to technical problems or abuse").'"'; ?> + '</h3>'; |
|
884 | 884 | result = result + '<table>'; |
885 | - result = result + '<tr><td>' + <?php echo '"' . _("Reason") . '"'; ?> + '</td><td>' + data.reason + '</td></tr>'; |
|
886 | - result = result + '<tr><td>' + <?php echo '"' . _("SP's Operator-Name") . '"'; ?> + '</td><td>' + data.opname + '</td></tr>'; |
|
887 | - result = result + '<tr><td>' + <?php echo '"' . _("User's outer ID") . '"'; ?> + '</td><td>' + data.outerid + '</td></tr>'; |
|
888 | - result = result + '<tr><td>' + <?php echo '"' . _("IdP email") . '"'; ?> + '</td><td>' + data.email + '</td></tr>'; |
|
889 | - result = result + '<tr><td>' + <?php echo '"' . _("Event's timestamp") . '"'; ?> + '</td><td>' + data.timestamp + '</td></tr>'; |
|
890 | - result = result + '<tr><td>' + <?php echo '"' . _("Calling-Station-Id") . '"'; ?> + '</td><td>' + data.mac + '</td></tr>'; |
|
891 | - result = result + '<tr><td>' + <?php echo '"' . _("Additional description") . '"'; ?> +'</td><td>' + data.freetext + '</td></tr>'; |
|
892 | - result = result + '<tr><td>' + <?php echo '"' . _("How to contact the user") . '"'; ?> +'</td><td>' + data.cdetails + '</td></tr>'; |
|
885 | + result = result + '<tr><td>' + <?php echo '"'._("Reason").'"'; ?> + '</td><td>' + data.reason + '</td></tr>'; |
|
886 | + result = result + '<tr><td>' + <?php echo '"'._("SP's Operator-Name").'"'; ?> + '</td><td>' + data.opname + '</td></tr>'; |
|
887 | + result = result + '<tr><td>' + <?php echo '"'._("User's outer ID").'"'; ?> + '</td><td>' + data.outerid + '</td></tr>'; |
|
888 | + result = result + '<tr><td>' + <?php echo '"'._("IdP email").'"'; ?> + '</td><td>' + data.email + '</td></tr>'; |
|
889 | + result = result + '<tr><td>' + <?php echo '"'._("Event's timestamp").'"'; ?> + '</td><td>' + data.timestamp + '</td></tr>'; |
|
890 | + result = result + '<tr><td>' + <?php echo '"'._("Calling-Station-Id").'"'; ?> + '</td><td>' + data.mac + '</td></tr>'; |
|
891 | + result = result + '<tr><td>' + <?php echo '"'._("Additional description").'"'; ?> +'</td><td>' + data.freetext + '</td></tr>'; |
|
892 | + result = result + '<tr><td>' + <?php echo '"'._("How to contact the user").'"'; ?> +'</td><td>' + data.cdetails + '</td></tr>'; |
|
893 | 893 | } |
894 | 894 | result = result + '</div>'; |
895 | 895 | showInfo(result, title); |
@@ -906,7 +906,7 @@ discard block |
||
906 | 906 | if ($('#mac').val().length > 0) { |
907 | 907 | if ($('#mac').val().length != 17) { |
908 | 908 | $('#mac').addClass('error_input'); |
909 | - $('#mac').attr('title', <?php echo '"' . _("MAC address is incomplete") . '"'; ?>); |
|
909 | + $('#mac').attr('title', <?php echo '"'._("MAC address is incomplete").'"'; ?>); |
|
910 | 910 | } else { |
911 | 911 | $('#mac').removeClass('error_input'); |
912 | 912 | $('#mac').attr('title', ''); |
@@ -915,7 +915,7 @@ discard block |
||
915 | 915 | if ($(this).attr('id') == 'email' && $(this).val().length > 0) { |
916 | 916 | if (!isEmail($(this).val())) { |
917 | 917 | $('#email').addClass('error_input'); |
918 | - $('#email').attr('title', <?php echo '"' . _("Wrong format of email") . '"'; ?>); |
|
918 | + $('#email').attr('title', <?php echo '"'._("Wrong format of email").'"'; ?>); |
|
919 | 919 | } else { |
920 | 920 | $('#email').removeClass('error_input'); |
921 | 921 | $('#email').attr('title', ''); |
@@ -924,7 +924,7 @@ discard block |
||
924 | 924 | if ($(this).attr('id') == 'outer_id' && $(this).val().length > 0) { |
925 | 925 | if (!isEmail($(this).val(), true)) { |
926 | 926 | $('#outer_id').addClass('error_input'); |
927 | - $('#outer_id').attr('title', <?php echo '"' . _("Wrong format of outer ID") . '"'; ?>); |
|
927 | + $('#outer_id').attr('title', <?php echo '"'._("Wrong format of outer ID").'"'; ?>); |
|
928 | 928 | } else { |
929 | 929 | $('#outer_id').removeClass('error_input'); |
930 | 930 | $('#outer_id').attr('title', ''); |
@@ -933,7 +933,7 @@ discard block |
||
933 | 933 | if ($(this).attr('id') == 'opname' && $('#opname').val().length > 0) { |
934 | 934 | if (!isOperatorName($(this).val())) { |
935 | 935 | $('#opname').addClass('error_input'); |
936 | - $('#opname').attr('title', <?php echo '"' . _("Wrong string given as OperatorName") . '"'; ?>); |
|
936 | + $('#opname').attr('title', <?php echo '"'._("Wrong string given as OperatorName").'"'; ?>); |
|
937 | 937 | $('#spmanually').show(); |
938 | 938 | } else { |
939 | 939 | $('#opname').removeClass('error_input'); |