et Fri Jun 20 11:10:42 2003 EDT Modified files: /phpdoc/en/reference/pcre/functions preg-match.xml Log: added a note Index: phpdoc/en/reference/pcre/functions/preg-match.xml diff -u phpdoc/en/reference/pcre/functions/preg-match.xml:1.5 phpdoc/en/reference/pcre/functions/preg-match.xml:1.6 --- phpdoc/en/reference/pcre/functions/preg-match.xml:1.5 Mon Jun 16 16:03:02 2003 +++ phpdoc/en/reference/pcre/functions/preg-match.xml Fri Jun 20 11:10:41 2003 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.5 $ --> +<!-- $Revision: 1.6 $ --> <!-- splitted from ./en/functions/pcre.xml, last change in rev 1.2 --> <refentry id="function.preg-match"> <refnamediv> @@ -55,6 +55,13 @@ <parameter>subject</parameter>. <function>preg_match</function> returns &false; if an error occured. </para> + <note> + <para> + Do not use <function>preg_match</function> if you only want to check if + one string is contained in another string. Use <function>strpos</function> + or <function>strstr</function> instead. + </para> + </note> <para> <example> <title>Find the string of text "php"</title>
-- PHP Documentation Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php