note 93317 added to function.ldap-connect

From: Date: Wed, 02 Sep 2009 20:35:11 +0000
Subject: note 93317 added to function.ldap-connect
Groups: php.notes 
Request: Send a blank email to php-notes+get-160172@lists.php.net to get a copy of this message
An addition to trying to setup failover. After doing the ldap_connect, do the ldap_bind. If ldap_bind fails, use the command ldap_errno to get the error number. If the error number is 81, that represents the server is down. That is the only time we do a failover to our backup ldap server. Another thing to consider is the error could be 49, then do ldap_get_option($this->ds,LDAP_OPT_ERROR_NUMBER,$optErrorNumber);. This will return extended data and if the data code in that is 532 or 773, the bind failure will be caused by the password being expired and requiring a password update before the bind will succeed. ---- Server IP: 208.69.120.35 Probable Submitter: 198.160.140.110 ---- Manual Page -- http://www.php.net/manual/en/function.ldap-connect.php Edit -- https://master.php.net/note/edit/93317 Del: integrated -- https://master.php.net/note/delete/93317/integrated Del: useless -- https://master.php.net/note/delete/93317/useless Del: bad code -- https://master.php.net/note/delete/93317/bad+code Del: spam -- https://master.php.net/note/delete/93317/spam Del: non-english -- https://master.php.net/note/delete/93317/non-english Del: in docs -- https://master.php.net/note/delete/93317/in+docs Del: other reasons-- https://master.php.net/note/delete/93317 Reject -- https://master.php.net/note/reject/93317 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#160172) next »