lDAP Enrolment field neede

lDAP Enrolment field neede

by Mawuli Kuivi -
Number of replies: 5
I think the ldap enrolment method is missing a field called enrol_ldap_search_sub which tells the ldap search whether to search sub directories of the tree given.
This is needed from the code
        if ($CFG->enrol_ldap_search_sub){
//use ldap_search to find first user from subtree
$ldap_result = ldap_search($ldap_connection,
$context,
$ldap_search_pattern,
$ldap_fields_wanted);

} else {
//search only in this context
$ldap_result = ldap_list($ldap_connection,
$context,
$ldap_search_pattern,
$ldap_fields_wanted,0,0);
}
Please add this to the page.

Thanks.
Average of ratings: -
In reply to Mawuli Kuivi

Re: lDAP Enrolment field neede

by Martín Langhoff -
LOL! You're right -- I forgot to put it in the form. Adding it to the form would be trivial. I'll do it soon. If you are in a hurry, you may want to add it yourself to the form (it's really easy). If you do, would you send me a patch?

cheers,


martin
In reply to Martín Langhoff

Re: lDAP Enrolment field neede

by Mawuli Kuivi -
I am NOT in a hurry. Just wanted you to know so that it can be fix for the 1.5 reease. Let me know when you are done.

Also, after you are done fixing it, please if you have some time, can you send me the steps to take to in creating a patch so that next time l find something,l can create a patch for it.

Thanks. smile
In reply to Mawuli Kuivi

Re: lDAP Enrolment field neede

by Martín Langhoff -
To follow DEV more closely, and post nice patches...

Switch from running the nighly tarballs to using anonymous cvs (you can do a daily "cvs update -dP" to get the latest updates). Then, if you've modified a file and you want to send me the patch, do "cvs diff -u directory/file.php > fixing_foo_problem.patch" and post the resulting file.

I think you are doing a great job in pointing out bugs (it really helps as your reports are very detailed). Thanks!