JLDAP/connect
From Joomla! Documentation
< API16:JLDAP
The "API16" namespace is an archived namespace. This page contains information for a Joomla! version which is no longer supported. It exists only as a historical reference, it will not be improved and its content may be incomplete and/or contain broken links.
Description[edit]
Connect to server boolean True if successful public
<! removed transcluded page call, red link never existed >
Syntax[edit]
connect()
Returns[edit]
boolean True if successful public
Defined in[edit]
libraries/joomla/client/ldap.php
Importing[edit]
jimport( 'joomla.client.ldap' );
Source Body[edit]
function connect()
{
if ($this->host == '') {
return false;
}
$this->_resource = @ ldap_connect($this->host, $this->port);
if ($this->_resource)
{
if ($this->use_ldapV3) {
if (!@ldap_set_option($this->_resource, LDAP_OPT_PROTOCOL_VERSION, 3)) {
return false;
}
}
if (!@ldap_set_option($this->_resource, LDAP_OPT_REFERRALS, intval($this->no_referrals))) {
return false;
}
if ($this->negotiate_tls) {
if (!@ldap_start_tls($this->_resource)) {
return false;
}
}
return true;
} else {
return false;
}
}
<! removed transcluded page call, red link never existed >
Examples[edit]
Code Examples[edit]