ID: 21119
Updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
-Status: Open
+Status: Closed
Bug Type: Feature/Change Request
Operating System: NA
PHP Version: 4.2.3
New Comment:
if (in_array($x, array ('cats', 'dogs', 'birds))) {
should be as useful as introducing a new construct.
Derick
Previous Comments:
------------------------------------------------------------------------
[2002-12-20 13:01:08] [EMAIL PROTECTED]
Here's a suggestion that we(local developers in Carbondale,IL) all feel
would improve usability of the control structures in PHP.
What if in this statement...
if (($x == 'cats') && ($x == 'dogs') && ($x == 'birds')) {
we instead could say...
if ($x IN 'cats','dogs','birds') {
This would reduce typing and allow you to compare lists(arrays) in your
conditional statements without using array functions.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=21119&edit=1