PHP
downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

ldap_get_values_len> <ldap_get_entries
Last updated: Fri, 30 Jan 2009

view this page in

ldap_get_option

(PHP 4 >= 4.0.4, PHP 5)

ldap_get_option指定したオプションの現在の値を得る

説明

bool ldap_get_option ( resource $link_identifier , int $option , mixed &$retval )

retval を、指定したオプションの値として設定します。

パラメータ

link_identifier

ldap_connect() が返す LDAP リンク ID。

option

パラメータ option は以下のいずれかとなります。

オプション
LDAP_OPT_DEREF integer
LDAP_OPT_SIZELIMIT integer
LDAP_OPT_TIMELIMIT integer
LDAP_OPT_NETWORK_TIMEOUT integer
LDAP_OPT_PROTOCOL_VERSION integer
LDAP_OPT_ERROR_NUMBER integer
LDAP_OPT_REFERRALS bool
LDAP_OPT_RESTART bool
LDAP_OPT_HOST_NAME string
LDAP_OPT_ERROR_STRING string
LDAP_OPT_MATCHED_DN string
LDAP_OPT_SERVER_CONTROLS array
LDAP_OPT_CLIENT_CONTROLS array

retval

これが、オプションの値として設定されます。

返り値

成功した場合に TRUE を、失敗した場合に FALSE を返します。

例1 プロトコルのバージョンを調べる

<?php
// $ds はディレクトリサーバへの有効なリンクIDです
if (ldap_get_option($dsLDAP_OPT_PROTOCOL_VERSION$version)) {
    echo 
"使用中のプロトコルのバージョン: $version\n";
} else {
    echo 
"プロトコルのバージョンを決定することができません\n";
}
?>

注意

注意: この関数は、OpenLDAP 2.x.x または Netscape Directory SDK x.x を使用した場合にのみ利用可能です。

参考



add a note add a note User Contributed Notes
ldap_get_option
There are no user contributed notes for this page.

ldap_get_values_len> <ldap_get_entries
Last updated: Fri, 30 Jan 2009
 
 
show source | credits | sitemap | contact | advertising | mirror sites