svn: /phpdoc/en/trunk/reference/array/functions/ in-array.xml
| From: | David Tajchreber | Date: | Wed, 20 Apr 2011 13:58:29 +0000 |
| Subject: | svn: /phpdoc/en/trunk/reference/array/functions/ in-array.xml | ||
| Groups: | php.doc.cvs | ||
| Request: | Send a blank email to doc-cvs+get-7984@lists.php.net to get a copy of this message | ||
dtajchreber Wed, 20 Apr 2011 13:58:29 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=310392
Log:
Fixed #54574 - clarified that in_array uses loose comparison by default
Bug: http://bugs.php.net/54574 (Open) is_array doesn't
have any warning about unexpected type casting
Changed paths:
U phpdoc/en/trunk/reference/array/functions/in-array.xml
Modified: phpdoc/en/trunk/reference/array/functions/in-array.xml
===================================================================
--- phpdoc/en/trunk/reference/array/functions/in-array.xml 2011-04-20 13:41:26 UTC (rev 310391)
+++ phpdoc/en/trunk/reference/array/functions/in-array.xml 2011-04-20 13:58:29 UTC (rev 310392)
@@ -3,7 +3,7 @@
<refentry xml:id="function.in-array" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>in_array</refname>
- <refpurpose>Checks if a value exists in an array</refpurpose>
+ <refpurpose>Checks if a value exists in an array using loose comparison if
</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
@@ -11,10 +11,11 @@
<type>bool</type><methodname>in_array</methodname>
<methodparam><type>mixed</type><parameter>needle</parameter></methodparam>
<methodparam><type>array</type><parameter>haystack</parameter></methodparam>
- <methodparam
choice="opt"><type>bool</type><parameter>strict</parameter></methodparam>
+ <methodparam
choice="opt"><type>bool</type><parameter>strict</parameter><initializer>&false;</initializer></methodparam>
</methodsynopsis>
<para>
- Searches <parameter>haystack</parameter> for
<parameter>needle</parameter>.
+ Searches <parameter>haystack</parameter> for
<parameter>needle</parameter> using loose comparison
+ unless <parameter>strict</parameter> is set.
</para>
</refsect1>
<refsect1 role="parameters">