ID: 27225
Updated by: [EMAIL PROTECTED]
Reported By: chris dot walsh at pni dot com
-Status: Open
+Status: Wont fix
Bug Type: Feature/Change Request
Operating System: Linux
PHP Version: 4.3.5RC2
New Comment:
if (in_array("a", array("a", "b", "c"))) works fine for this :)
Previous Comments:
------------------------------------------------------------------------
[2004-02-11 17:10:40] chris dot walsh at pni dot com
Description:
------------
Looking for a comparison operator/function to similar to the mysql "in"
function.
This could be used to replace long if statments:
if($a=="b" || $a=="c" || $a=="d")
something like
if(in($a,"b","c","d"))
or
if($a=="b"||"c"||"d")
or
if($a|="b","c","d")
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=27225&edit=1