1--TEST--
2ldap_connect() - Connection using default host from openldap's ldap.conf
3--CREDITS--
4David Caldwell <david@galvanix.com>
5--EXTENSIONS--
6ldap
7--SKIPIF--
8<?php
9ob_start();
10phpinfo();
11if (!preg_match("/vendor name => openldap/i", ob_get_clean()))
12    die("skip not openldap");
13?>
14--ENV--
15LDAPCONF={PWD}/ldap_connect_ldap_conf.conf
16--FILE--
17<?php
18$link = ldap_connect();
19ldap_get_option($link, LDAP_OPT_HOST_NAME, $host);
20var_dump($host);
21?>
22--EXPECT--
23string(16) "example.com:3141"
24