N
neelesh
Hi....
I am using perl with open LDAP over linux and i am getting error of
invalid dn when i use following statement.....
$result = $ldap->add(dn =>'$dn', attr => [$attr]);
where $dn and $attr are variable but when i use following statement
then code succcessfully runs
$result = $ldap->add(dn => 'pidTable=test,dc=nycube',attr =>['pid'
=> 'test','objectClass' => 'pidTable','userid' => ['testing'],]);
here $str is constructed by concatenation of $key=>$value pair i want
to use this method because each time when i am calling this function
then passed no of arguments may be different so i construct string by
concatenation of $key=>$value pair and then i passed it to this
function.
so i want to ask why this error is generating.Is there any possibility
inthe case of earlier ldap->add statment that variableds inside the
parentheses are not interpreted before the execution of ldap->add
statement and can i use this statement
$result = $ldap->add(dn =>'$dn', attr => [$attr]);
reply me as soon as possible.
Thanks,
Neelesh Vijaivargia
I am using perl with open LDAP over linux and i am getting error of
invalid dn when i use following statement.....
$result = $ldap->add(dn =>'$dn', attr => [$attr]);
where $dn and $attr are variable but when i use following statement
then code succcessfully runs
$result = $ldap->add(dn => 'pidTable=test,dc=nycube',attr =>['pid'
=> 'test','objectClass' => 'pidTable','userid' => ['testing'],]);
here $str is constructed by concatenation of $key=>$value pair i want
to use this method because each time when i am calling this function
then passed no of arguments may be different so i construct string by
concatenation of $key=>$value pair and then i passed it to this
function.
so i want to ask why this error is generating.Is there any possibility
inthe case of earlier ldap->add statment that variableds inside the
parentheses are not interpreted before the execution of ldap->add
statement and can i use this statement
$result = $ldap->add(dn =>'$dn', attr => [$attr]);
reply me as soon as possible.
Thanks,
Neelesh Vijaivargia