]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - pgsrc/Help%2FLdapSearchPlugin
Update PHP Doc
[SourceForge/phpwiki.git] / pgsrc / Help%2FLdapSearchPlugin
1 Date: Fri, 11 Jan 2013 11:16:51 +0000
2 Mime-Version: 1.0 (Produced by PhpWiki 1.4.0)
3 Content-Type: application/x-phpwiki;
4   pagename=Help%2FLdapSearchPlugin;
5   flags=PAGE_LOCKED;
6   charset=UTF-8
7 Content-Transfer-Encoding: binary
8
9 The **~LdapSearch** [[Help:WikiPlugin|plugin]] displays a LDAP query as table.
10
11 == Usage ==
12 {{{
13 <<LdapSearch>>
14 <<LdapSearch
15            host="localhost"
16            port=389
17            basedn=""
18            filter="(cn=*)"
19            attributes=""
20 >>
21 <<LdapSearch host=ldap.example.com filter="(ou=web-team)"
22                       attributes="sn cn telephonenumber">>
23 <<LdapSearch host="ldap.itd.umich.edu" basedn="" filter="(sn=jensen)" attributes="cn drink">>
24 <<LdapSearch host=ldap.example.com attributes="cn sn telephonenumber">>
25 <<LdapSearch host=bugs.debian.org port=10101 basedn="dc=current,dc=bugs,dc=debian,dc=org"
26                       filter="(debbugsPackage=phpwiki)"
27                       attributes="debbugsSeverity debbugsState debbugsTitle">>
28 }}}
29
30 == Arguments ==
31
32 {| class="bordered"
33 |-
34 ! Argument
35 ! Description
36 ! Default value
37 |-
38 | **host**
39 | hostname or ip or ldap:// uri to connect to.
40 | from LDAP_AUTH_HOST or localhost
41 |-
42 | **port**
43 | portnumber to connect to.
44 | from LDAP_AUTH_HOST or 389
45 |-
46 | **basedn**
47 | connect string: "ou=Users,o=Development,dc=mycompany.com"
48 | LDAP_BASE_DN
49 |-
50 | **filter**
51 | Optional ldap_search() filter argument
52 | "(cn=*)"
53 |-
54 | **attributes**
55 | space separated fields to return as table columns: "cn sn"
56 | empty
57 |-
58 | **options**
59 | ldap_set_option(). Column separated name=value pairs. Esp. needed for Windows Active directory: "LDAP_OPT_PROTOCOL_VERSION=3:LDAP_OPT_REFERRALS=0"
60 | LDAP_SET_OPTION if host == LDAP_AUTH_HOST
61 |-
62 | **user**
63 | user and password are required for Windows Active directory.
64 | Default: LDAP_AUTH_USER if host == LDAP_AUTH_HOST
65 |-
66 | **password**
67 | user and password are required for Windows Active directory.
68 | Default: LDAP_AUTH_PASSWORD if host == LDAP_AUTH_HOST
69 |}
70
71 == Examples ==
72
73 <<WikiFormRich action=LdapSearch
74         editbox[] name=host value=bugs.debian.org size=80
75         editbox[] name=port value=10101 size=80
76         editbox[] name=basedn value="dc=current,dc=bugs,dc=debian,dc=org" size=80
77         editbox[] name=filter value="(debbugsPackage=phpwiki)" size=80
78         editbox[] name=attributes value="debbugsSeverity debbugsState debbugsTitle" size=80
79         submit[] reset[]
80 >>
81
82 == Author ==
83 * John Lines
84
85 == See Also ==
86
87 <noinclude>
88 ----
89 [[PhpWikiDocumentation]] [[CategoryWikiPlugin]]
90 </noinclude>