mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 17:08:54 +00:00
Updating yp_first example to proper use of array return.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@44009 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
6e6ca0cdf3
commit
a8da862ae2
1 changed files with 4 additions and 4 deletions
|
@ -210,10 +210,10 @@ echo "Matched entry is: " . $entry;
|
|||
<title>Example for the NIS first</title>
|
||||
<programlisting role="php">
|
||||
<?php
|
||||
$entry = yp_first($domain, "passwd.byname");
|
||||
$key = key($entry);
|
||||
echo "First entry in this map has key " . $key
|
||||
. " and value " . $entry[$key];
|
||||
$entry = yp_first($domain, "passwd.byname");
|
||||
$key = $entry ["key"];
|
||||
$value = $entry ["value"];
|
||||
echo "First entry in this map has key " . $key . " and value " . $value;
|
||||
?>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
|
Loading…
Reference in a new issue