philip          Mon Aug 16 19:39:05 2004 EDT

  Modified files:              
    /phpdoc/en/reference/regex/functions        eregi.xml 
  Log:
  Closes bug #29714 (returns # matches on success, so mixed not bool), 
  and also completed the example.
  
  
http://cvs.php.net/diff.php/phpdoc/en/reference/regex/functions/eregi.xml?r1=1.5&r2=1.6&ty=u
Index: phpdoc/en/reference/regex/functions/eregi.xml
diff -u phpdoc/en/reference/regex/functions/eregi.xml:1.5 
phpdoc/en/reference/regex/functions/eregi.xml:1.6
--- phpdoc/en/reference/regex/functions/eregi.xml:1.5   Tue Aug  3 11:51:10 2004
+++ phpdoc/en/reference/regex/functions/eregi.xml       Mon Aug 16 19:39:05 2004
@@ -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'!";
 }
 ?>

Reply via email to