Closes bug #29714 (returns # matches on success, so mixed not bool),

and also completed the example.


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@166544 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Philip Olson 2004-08-16 23:39:05 +00:00
parent ea9a85ca4a
commit 8703a13bd1

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.5 $ -->
<!-- $Revision: 1.6 $ -->
<!-- splitted from ./en/functions/regex.xml, last change in rev 1.2 -->
<refentry id="function.eregi">
<refnamediv>
@ -9,7 +9,7 @@
<refsect1>
<title>Description</title>
<methodsynopsis>
<type>bool</type><methodname>eregi</methodname>
<type>mixed</type><methodname>eregi</methodname>
<methodparam><type>string</type><parameter>pattern</parameter></methodparam>
<methodparam><type>string</type><parameter>string</parameter></methodparam>
<methodparam choice="opt"><type>array</type><parameter>&amp;regs</parameter></methodparam>
@ -25,7 +25,8 @@
<programlisting role="php">
<![CDATA[
<?php
if (eregi("z", $string)) {
$string = 'XYZ';
if (eregi('z', $string)) {
echo "'$string' contains a 'z' or 'Z'!";
}
?>