7.113 NIS
7 Index des fonctions
Manuel PHP
. Introduction . Pré-requis . Installation . Configuration à l'exécution . Constantes prédefinies . yp_all . yp_cat . yp_err_string . yp_errno . yp_first . yp_get_default_domain . yp_master ->yp_match . yp_next . yp_order
|
7.113.13 yp_match()Retourne la ligne associée[ Exemples avec yp_match ] PHP 3>= 3.0.7, PHP 4
string
yp_match (
string
domain
,
string
map
,
string
key
)
yp_match
retourne la valeur associée
à la clé passée en argument, pour la carte
spécifiée, ou
FALSE
. La clé doit exister et
être exacte.
Exemple de recherche NIS |
<?php $entry = yp_match($domain, "passwd.byname", "joe"); echo "La valeur trouvée est : " . $entry; ?>
|
Dans le cas présent, ce pourrait être:
joe:##joe:11111:100:Joe User:/home/j/joe:/usr/local/bin/bash
Voir aussi
yp-get-default-domain
.
|