[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: How to pass details from a file using ldap_modify



Why not take a look at LDAPExplorer and Sldapa which seem to do what you are
trying to do.

  Iain


on 29/6/00 9:10 am, Antonin Novak at noc@cca.cz wrote:

> I have used PHP to access my LDAP database and produce web
> pages of the information.
> 
> I am looking to be able amend the data on the web page and use
> the amended page to modify teh database entry.
> 
> I have copied the information from the screen into a file in ldif
> format, but I cannot find the syntax of how to pass this data to
> LDAP.
> 
> My coding is as follows :-
> 
> $ds=ldap_connect("localhost:22999)
> if ($ds)
> {
> 
> $r=ldap_bind($ds,"cn=manager,dc=pkus,dc=cz","secret");
> $sr=ldap_modify($ds,dc=pkus,dc=cz","-f
> /tmp/ldap/zamestnance.mod");
> 
> When I try to run using this syntax I get the following error
> Expected array as the last element.
> 
> can anyone help me please?
> 
> Tony
> 
> ----------------------------------------------------------------
> 
> Antonin Ch. Novak                    mailto:Antonin.Novak@cca.cz
> Systemovy administrator
> Systemova a technicka podpora
> CCA spol. s r.o.                    Web: http://www.cca.cz
> Kratka 8,  
> 301 17 Plzen
> Czech Republic
> 
> Tel: +42 019 7221253
> Fax: +42 019 7222931