Prior to PHP 8.1.0, most LDAP functions operate on or return resources (e.g. ldap_connect returns a positive LDAP link identifier required by most LDAP functions).