protected function getMenuItemInternalAttributes()
 {
     if (DEBUG_ENABLED && (($fargs = func_get_args()) || ($fargs = 'NOARGS'))) {
         debug_log('Entered (%%)', 129, 0, __FILE__, __LINE__, __METHOD__, $fargs);
     }
     if (DEBUGTMP) {
         printf('<font size=-2>%s</font><br />', __METHOD__);
     }
     if (get_request('show_internal_attrs', 'REQUEST')) {
         $href = sprintf('cmd=template_engine&%s&junk=', $this->url_base, random_junk());
         return sprintf($this->layout['action'], IMGDIR, 'tools-no.png', _('Hide'), htmlspecialchars($href), '', _('Hide internal attributes'));
     } else {
         $href = sprintf('cmd=template_engine&show_internal_attrs=true&%s', $this->url_base);
         return sprintf($this->layout['action'], IMGDIR, 'tools.png', _('Show'), htmlspecialchars($href), '', _('Show internal attributes'));
     }
 }
Example #2
0
<?php

/**
 * This script alters the session variable 'tree', collapsing it
 * at the dn specified in the query string.
 *
 * Note: this script is equal and opposite to expand.php
 *
 * @package phpLDAPadmin
 * @subpackage Tree
 * @see expand.php
 */
/**
 */
require './common.php';
$dn = get_request('dn', 'GET', true);
$tree = get_cached_item($app['server']->getIndex(), 'tree');
$entry = $tree->getEntry($dn);
$entry->close();
set_cached_item($app['server']->getIndex(), 'tree', 'null', $tree);
header(sprintf('Location:index.php?server_id=%s&junk=%s#%s%s', $app['server']->getIndex(), random_junk(), htmlid($app['server']->getIndex(), $dn), app_session_param()));
die;