Skip to content
Snippets Groups Projects
Commit 49079b27 authored by Andreas Åkre Solberg's avatar Andreas Åkre Solberg
Browse files

Improving User interface for single logout...

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@1253 44740490-163a-0410-bde0-09ae8108e29a
parent 02e27e92
No related branches found
No related tags found
No related merge requests found
......@@ -50,14 +50,24 @@ $lang = array(
'pt-BR' => 'Voltar a instalação do simpleSAMLphp',
),
'loggedoutfrom' => array (
'no' => 'Du er nå logget ut fra %SP%.',
'en' => 'You are now successfully logged out from %SP%.',
),
'also_from' => array (
'no' => 'Du er også logget inn på disse tjenestene:',
'en' => 'You are also logged in on these services:',
),
'logout_all_question' => array (
'no' => 'Vil du logge ut fra alle tjenestene ovenfor?',
'en' => 'Do you want to logout from all the services above?',
),
'logout_all' => array (
'no' => 'Ja, alle tjenestene over',
'en' => 'Yes, all services',
),
'logout_only' => array (
'no' => 'Nei, bare %SP%',
'en' => 'No, only %SP%',
),
'description' => array (
'no' => 'Du har startet en <strong>global utlogging</strong> fra tjenesten <strong>%REQUESTERNAME%</strong>. Global utlogging betyr at du vil bli logget ut fra alle tjenestene vist nedenfor.',
......
......@@ -81,19 +81,17 @@ function sendResponse() {
<div id="nojavascriptframe">
<iframe style="margin: 1em; width: 90%; height: 5em; border: 1px solid #eee" src="SingleLogoutServiceiFrameNoJavascript.php?response=<?php echo urlencode($this->data['logoutresponse']); ?>"></iframe>
</div>
<?php
foreach ($this->data['sparray'] AS $sp) {
echo '<iframe class="hiddeniframe" onload="xajax_updateslostatus()" style="border: 1px solid #888; width: 80%; height: 100px"
src="' . htmlentities($sp['url']) . '" ></iframe>' . "\n";
}
?>
</noscript>
<div id="requirejavascript" style="display: none">
<?php
......@@ -101,18 +99,26 @@ function sendResponse() {
$requestername = is_array($this->data['requesterName']) ?
$this->getTranslation($this->data['requesterName']) : $this->data['requesterName'];
echo('<p>' . $this->t('{logout:description}', array('%REQUESTERNAME%' => $requestername)) . '</p>');
#echo('<p>' . $this->t('{logout:description}', array('%REQUESTERNAME%' => $requestername)) . '</p>');
?>
<!-- <div class="loggedout"><?php echo($this->t('{logout:logged_out}', array('%REQUESTERNAME%' => $requestername))); ?></div> -->
<?php
echo('<div><img style="float: left; margin-right: 12px" src="/' . $this->data['baseurlpath'] . 'resources/icons/gn/success-l.png" alt="Successful logout" />');
echo('<p style="padding-top: 16px; ">' . $this->t('{logout:loggedoutfrom}', array('%SP%' => '<strong>' .$requestername.'</strong>')) . '</p>');
echo('<p style="height: 0px; clear: left;"></p>');
echo('</div>');
echo('<div style="margin-top: 3em; clear: both">');
echo('<p style="margin-bottom: .5em">' . $this->t('{logout:also_from}') . '</p>');
echo '<table id="slostatustable">';
/** Remove initiated from. showed above instead
echo '<tr class="initiated" id="e_initiated">' . "\n";
echo ' <td><img style="float: left; margin: 3px" src="/' . $this->data['baseurlpath'] .
......@@ -121,15 +127,16 @@ function sendResponse() {
echo ' <td>' . $requestername . '</td>' ."\n";
echo '</tr>' . "\n";
*/
foreach ($this->data['sparrayNoLogout'] AS $spentityid => $sp) {
$spname = is_array($sp['name']) ? $this->getTranslation($sp['name']) : $sp['name'];
echo '<tr class="initiated" id="e' . sha1($spentityid) . '">' . "\n";
echo ' <td><img style="float: left; margin: 3px" src="/' . $this->data['baseurlpath'] .
echo ' <td class="statustext">Logout not supported</td>';
echo ' <td ><img style="" src="/' . $this->data['baseurlpath'] .
'resources/icons/silk/delete.png" alt="Initiated from" /></td>' . "\n";
echo ' <td>Logout not supported</td>';
echo ' <td>' . $spname . '</td>' ."\n";
echo '</tr>' . "\n";
}
......@@ -140,19 +147,23 @@ function sendResponse() {
echo '<tr class="ready onhold" id="e' . sha1($spentityid) . '">' . "\n";
echo ' <td class="statustext">';
echo ' <span class="completed">' . $this->t('{logout:completed}') . '</span>' . "\n";
# echo ' <span class="onhold">' . $this->t('{logout:hold}') . '</span>' . "\n";
echo ' <span class="onhold"></span>' . "\n";
echo ' <span class="inprogress">' . $this->t('{logout:progress}') . '</span>' . "\n";
echo ' <span class="failed">' . $this->t('{logout:failed}') . '</span>' . "\n";
echo ' </td>';
echo ' <td class="icons">';
echo ' <img class="completed" src="/' . $this->data['baseurlpath'] . 'resources/icons/silk/accept.png" alt="Completed" />' . "\n";
echo ' <img class="onhold" src="/' . $this->data['baseurlpath'] . 'resources/icons/silk/control_pause.png" alt="SP SLO on hold" />' . "\n";
echo ' <img class="onhold" src="/' . $this->data['baseurlpath'] . 'resources/icons/service.png" alt="SP SLO on hold" />' . "\n";
echo ' <img class="inprogress" src="/' . $this->data['baseurlpath'] . 'resources/progress.gif" alt="Progress bar" />' . "\n";
echo ' <img class="failed" src="/' . $this->data['baseurlpath'] . 'resources/icons/silk/exclamation.png" alt="Failed" />' . "\n";
echo ' </td>' . "\n";
echo ' <td class="statustext">';
echo ' <span class="completed">' . $this->t('{logout:completed}') . '</span>' . "\n";
echo ' <span class="onhold">' . $this->t('{logout:hold}') . '</span>' . "\n";
echo ' <span class="inprogress">' . $this->t('{logout:progress}') . '</span>' . "\n";
echo ' <span class="failed">' . $this->t('{logout:failed}') . '</span>' . "\n";
echo ' </td>';
echo ' <td>' . $spname . '</td>' ."\n";
echo '</tr>' . "\n";
......@@ -170,9 +181,9 @@ function sendResponse() {
?>
<p id="confirmation" style="margin-top: 1em" ><?php echo $this->t('{logout:continue}'); ?> <br />
<input type="button" id="ok" name="ok" value="<?php echo $this->t('{logout:do_continue}'); ?>" />
<input type="button" id="cancel" name="cancel" value="<?php echo $this->t('{logout:cancel}'); ?>" />
<p id="confirmation" style="margin-top: 1em" ><?php echo $this->t('{logout:logout_all_question}'); ?> <br />
<input type="button" id="ok" name="ok" value="<?php echo $this->t('{logout:logout_all}'); ?>" />
<input type="button" id="cancel" name="cancel" value="<?php echo $this->t('{logout:logout_only}', array('%SP%' => $requestername)); ?>" />
</p>
<div id="interrupt" style="margin-top: 1em; border: 1px solid #ccc; padding: 1em; background: #eaeaea" >
......
www/resources/icons/gn/notice-l.png

2.82 KiB

www/resources/icons/gn/stop-l.png

2.37 KiB

www/resources/icons/gn/success-l.png

3.56 KiB

www/resources/icons/gn/warning-l.png

2.21 KiB

www/resources/icons/service.png

676 B

table#slostatustable {
width: 100%;
/* width: 100%; */
border-collapse: collapse;
margin-bottom: 1em;
}
table#slostatustable tr td {
border-top: 1px solid #ccc;
/* border-top: 1px solid #ccc; */
padding-left: 4px;
padding-right: 4px;
}
table#slostatustable tr td.statustext {
min-width: 5em;
}
......@@ -14,7 +20,7 @@ table#slostatustable tr.inprogress td.statustext span.inprogress { display: inli
table#slostatustable tr.failed td.statustext span.failed { display: inline; }
table#slostatustable tr td.icons img {
margin: 3px;
/* margin: 3px; */
display: none;
}
table#slostatustable tr.completed td.icons img.completed { display: inline; }
......
......@@ -359,7 +359,7 @@ if (array_key_exists('name', $spmeta)) $spname = $spmeta['name'];
$et = new SimpleSAML_XHTML_Template($config, 'logout-iframe.php');
$et->data['header'] = 'Global logout';
$et->data['header'] = 'Logout';
$et->data['sparray'] = $sparray;
$et->data['sparrayNoLogout'] = $sparrayNoLogout;
......
......@@ -22,7 +22,7 @@ if (isset($session) ) {
$session->clean();
}
# sleep(max(0, rand(-5,15)));
sleep(max(0, rand(-3,5))*5);
if (isset($_GET['SAMLRequest'])) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment