Horde_Config::_configLDAPUser PHP Метод

_configLDAPUser() защищенный Метод

Subnodes will be parsed and added.
protected _configLDAPUser ( string $ctx, DomNode $node = null ) : array
$ctx string The context of the tag.
$node DomNode The DomNode representation of the tag.
Результат array A list of associative arrays with the LDAP configuration tree.
    protected function _configLDAPUser($ctx, $node = null)
    {
        if ($node) {
            $xpath = new DOMXPath($node->ownerDocument);
        }
        return array('user' => array('basedn' => array('_type' => 'text', 'required' => false, 'desc' => 'Base DN for searching the user\'s DN', 'default' => $this->_default($ctx . '|user|basedn', $node ? $xpath->evaluate('string(configsection/configstring[@name="basedn"])', $node) ?: '' : '')), 'uid' => array('_type' => 'text', 'required' => true, 'desc' => 'The username search key (set to samaccountname for AD).', 'default' => $this->_default($ctx . '|user|uid', $node ? $xpath->evaluate('string(configsection/configstring[@name="uid"])', $node) ?: 'uid' : 'uid')), 'filter_type' => array('required' => false, 'desc' => 'How to specify a filter for the user lists.', 'default' => $this->_default($ctx . '|user|filter_type', $node ? $xpath->evaluate('normalize-space(configsection/configswitch[@name="filter_type"]/text())', $node) ?: 'objectclass' : 'objectclass'), 'switch' => array('filter' => array('desc' => 'LDAP filter string', 'fields' => array('filter' => array('_type' => 'text', 'required' => true, 'desc' => 'The LDAP filter string used to search for users.', 'default' => $this->_default($ctx . '|user|filter', $node ? $xpath->evaluate('string(configsection/configstring[@name="filter"])', $node) ?: '(objectClass=*)' : '(objectClass=*)')))), 'objectclass' => array('desc' => 'List of objectClasses', 'fields' => array('objectclass' => array('_type' => 'stringlist', 'required' => true, 'desc' => 'The objectclass filter used to search for users. Can be a single objectclass or a comma-separated list.', 'default' => implode(', ', $this->_default($ctx . '|user|objectclass', $node ? $xpath->evaluate('string(configsection/configlist[@name="objectclass"])', $node) ?: array('*') : array('*'))))))))));
    }