diff --git a/modules/ldapstatus/templates/ldapstatus.php b/modules/ldapstatus/templates/ldapstatus.php index 6362e26347d6b02628f8e2bae1ff5071f50567c9..a1314aac2990c492ae4c40b96a2f76b2363379e8 100644 --- a/modules/ldapstatus/templates/ldapstatus.php +++ b/modules/ldapstatus/templates/ldapstatus.php @@ -88,6 +88,12 @@ foreach($this->data['sortedOrgIndex'] as $orgkey) { showRes('configMeta', $res, $this); echo('<td style="text-align: right">' . ceil($res['time']*1000) . ' ms</td>'); echo('</tr>'); + + if ($this->data['showcomments'] && array_key_exists('comment', $this->data['orgconfig'][$orgkey])) { + echo('<tr><td style="color: #400; padding-left: 5em; font-family: \'Arial Narrow\'; font-size: 85%" colspan="11">' . $this->data['orgconfig'][$orgkey]['comment'] . '</td></tr>'); + } + + } ?> </table> @@ -113,10 +119,13 @@ if ($sum > 0) { echo('</table>'); } if ($this->data['completeOf'] > $this->data['completeNo']) { - echo('<p>[ <a href="?reload=1">load more entries</a> | <a href="?reset=1">reset all entries</a> ]'); + echo('<p>[ <a href="?">load more entries</a> | <a href="?reset=1">reset all entries</a> ]'); } else { echo('<p>[ <a href="?reset=1">reset all entries</a> ]'); } +if (!$this->data['showcomments']) { + echo('<p>[ <a href="?showcomments=1">show comments</a> ]'); +} ?> diff --git a/modules/ldapstatus/www/index.php b/modules/ldapstatus/www/index.php index 26dce3517fde50f7b4abe1291409db01a4324746..2aaedd1b3f4353c9507b70651ec25e8cd2bd7e64 100644 --- a/modules/ldapstatus/www/index.php +++ b/modules/ldapstatus/www/index.php @@ -144,6 +144,7 @@ asort($ressortable); $t = new SimpleSAML_XHTML_Template($config, 'ldapstatus:ldapstatus.php'); +$t->data['showcomments'] = array_key_exists('showcomments', $_REQUEST); $t->data['completeNo'] = count($results); $t->data['completeOf'] = count($orgs); $t->data['results'] = $results;