This function gets the attribute type for all simple filter choices:
LDAP_FILTER_GE
LDAP_FILTER_LE
LDAP_FILTER_APPROX
LDAP_FILTER_EQUALITY
LDAP_FILTER_SUBSTRINGS
LDAP_FILTER_PRESENT
LDAP_FILTER_EXTENDED
LDAP_FILTER_AND
LDAP_FILTER_OR
LDAP_FILTER_NOT
A filter such as (mail-foo) will return the type mail.