fixed problems with export with PHP 5.3.2

This commit is contained in:
Roland Gruber 2010-05-09 15:45:09 +00:00
parent 6aa7441b9f
commit 8ff4dbee8c
3 changed files with 7 additions and 7 deletions

View File

@ -8,7 +8,7 @@ $Id$
Copyright (C) 2004 David Smith and phpLDAPadmin developers Copyright (C) 2004 David Smith and phpLDAPadmin developers
The original code was modified to fit for LDAP Account Manager by Roland Gruber. The original code was modified to fit for LDAP Account Manager by Roland Gruber.
Copyright (C) 2005 - 2006 Roland Gruber Copyright (C) 2005 - 2010 Roland Gruber
This program is free software; you can redistribute it and/or modify This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by it under the terms of the GNU General Public License as published by
@ -343,7 +343,7 @@ class PlaLdapExporter extends PlaAbstractExporter{
//get the attributes of the entry //get the attributes of the entry
$attrs = @ldap_get_attributes($this->ds,$this->entry_id); $attrs = @ldap_get_attributes($this->ds,$this->entry_id);
if( $attr = @ldap_first_attribute( $this->ds,$this->entry_id,$attrs ) ){ if( $attr = @ldap_first_attribute( $this->ds,$this->entry_id ) ){
//iterate over the attributes //iterate over the attributes
while( $attr ){ while( $attr ){
@ -354,7 +354,7 @@ class PlaLdapExporter extends PlaAbstractExporter{
$this->entry_array[$attr] = @ldap_get_values( $this->ds,$this->entry_id,$attr ); $this->entry_array[$attr] = @ldap_get_values( $this->ds,$this->entry_id,$attr );
} }
unset( $this->entry_array[$attr]['count'] ); unset( $this->entry_array[$attr]['count'] );
$attr = @ldap_next_attribute( $this->ds,$this->entry_id,$attrs ); $attr = @ldap_next_attribute( $this->ds,$this->entry_id );
}// end while attr }// end while attr
if(!$this->entry_id = @ldap_next_entry( $this->ds,$this->entry_id ) ){ if(!$this->entry_id = @ldap_next_entry( $this->ds,$this->entry_id ) ){

View File

@ -8,7 +8,7 @@ $Id$
Copyright (C) 2004 David Smith and phpLDAPadmin developers Copyright (C) 2004 David Smith and phpLDAPadmin developers
The original code was modified to fit for LDAP Account Manager by Roland Gruber. The original code was modified to fit for LDAP Account Manager by Roland Gruber.
Copyright (C) 2005 - 2006 Roland Gruber Copyright (C) 2005 - 2010 Roland Gruber
This program is free software; you can redistribute it and/or modify This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by it under the terms of the GNU General Public License as published by
@ -1284,7 +1284,7 @@ function pla_ldap_search( $filter, $base_dn=null, $attrs=array(), $scope='sub',
$return[$dn]['dn'] = $dn; $return[$dn]['dn'] = $dn;
//get the first attribute of the entry //get the first attribute of the entry
if($attr = ldap_first_attribute($ds,$entry_id,$attrs)) if($attr = ldap_first_attribute($ds,$entry_id))
//iterate over the attributes //iterate over the attributes
while($attr){ while($attr){
@ -1301,7 +1301,7 @@ function pla_ldap_search( $filter, $base_dn=null, $attrs=array(), $scope='sub',
else else
$return[$dn][$attr] = $values; $return[$dn][$attr] = $values;
$attr = ldap_next_attribute($ds,$entry_id,$attrs); $attr = ldap_next_attribute($ds,$entry_id);
}// end while attr }// end while attr
$entry_id = ldap_next_entry($ds,$entry_id); $entry_id = ldap_next_entry($ds,$entry_id);

View File

@ -74,7 +74,7 @@ if( ! $search ) {
} }
$entry = ldap_first_entry( $ds, $search ); $entry = ldap_first_entry( $ds, $search );
$attrs = ldap_get_attributes( $ds, $entry ); $attrs = ldap_get_attributes( $ds, $entry );
$attr = ldap_first_attribute( $ds, $entry, $attrs ); $attr = ldap_first_attribute( $ds, $entry );
$values = ldap_get_values_len( $ds, $entry, $attr ); $values = ldap_get_values_len( $ds, $entry, $attr );
$count = $values['count']; $count = $values['count'];