php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #3200 LDAP Modify Error
Submitted: 2000-01-13 04:53 UTC Modified: 2000-07-28 13:46 UTC
From: hadi at ulakbim dot gov dot tr Assigned:
Status: Closed Package: LDAP related
PHP Version: 4.0 Beta 3 OS: Solaris 2.0
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: hadi at ulakbim dot gov dot tr
New email:
PHP Version: OS:

 

 [2000-01-13 04:53 UTC] hadi at ulakbim dot gov dot tr
Hi,
My PHP version 4.0 Beta 3. I use Netscape Directory Server 4.11 as LDAP server and OpenLDAP client libraries as client side. LDAP search works successfully, but modify doesn't work. My sample code is like this:

$ds      = ldap_connect("localhost","389");
$base_dn = "o=ulakbim";
$filter  = "uid=hadi";
$sr      = ldap_search($ds, $base_dn, $filter);
$info    = ldap_get_entries($ds, $sr);

$info    = $info[0];  // First Entry

// $info["mail"]    = "hadi@ulakbim.gov.tr";
$info["mail"][0] = "hadi@ulakbim.gov.tr";

echo "Modifying..."; <-- This message can't be seen.
ldap_modify($ds, "uid=hadi,o=ulakbim", $info); <-- There is no output generated and this command doesn't not run.

This may not be a bug, but I don't know which structure I must use for '$info'. And I haven't found any example.
Could you send me an example code for modification. Thanks.

Regards,

Mustafa Hadi Dilek 

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-01-13 05:09 UTC] hadi at ulakbim dot gov dot tr
Hi,
My PHP version 4.0 Beta 3. I use Netscape Directory Server 4.11 as LDAP server and
OpenLDAP client libraries as client side. LDAP search works successfully, but modify doesn't work.
My sample code is like this:

$ds      = ldap_connect("localhost","389");
ldap_bind($ds, "uid=hadi,o=ulakbim", $pwd);
$base_dn = "o=ulakbim";
$filter  = "uid=hadi";
$sr      = ldap_search($ds, $base_dn, $filter);
$info    = ldap_get_entries($ds, $sr);

$info    = $info[0];  // First Entry
// $info["mail"]    = "hadi@ulakbim.gov.tr";
$info["mail"][0] = "hadi@ulakbim.gov.tr";

echo "Modifying..."; <-- This message can't be seen.
ldap_modify($ds, , $info); <-- There is no output
generated and this command doesn't not run.

This may not be a bug, but I don't know which structure I must use for '$info'.
And I couldn't found any example.
Could you send me an example code for modification.
Thanks.

Regards,

Mustafa Hadi Dilek
 [2000-07-24 00:05 UTC] sniper at cvs dot php dot net
This is rather old bug-report..

Have you tried a newer version of php? There have been
some fixes regarding ldap_modify().

To get the possible error message, add following line right after the ldap_modify() line:

echo ldap_error($ds);

--Jani


 [2000-07-28 13:46 UTC] sniper@php.net
No feedback.
If this is still a problem, reopen this bug report.

--Jani


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 12:01:31 2024 UTC