Hi-
I was wondering if php had a case function?
Instead of building a large if/elseif/else block I would like to do a case
$page in (list).
Thanks in advance,
Max
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
switch()
{
case a:
case b:
case c:
default:
}
RTFM
- Original Message -
From: Max Clark [EMAIL PROTECTED]
To:
Sent: Thursday, December 19, 2002 12:19 PM
Subject: [PHP] case statement?
Hi-
I was wondering if php had a case function?
Instead of building a large if/elseif/else
On Thu, 19 Dec 2002, Max Clark wrote:
I was wondering if php had a case function?
Instead of building a large if/elseif/else block I would like to do a
case $page in (list).
switch function ...
http://www.php.net/manual/en/control-structures.switch.php
~Chris
--
PHP General
-Original Message-
From: Max Clark [mailto:[EMAIL PROTECTED]]
Sent: 19 December 2002 18:19
I was wondering if php had a case function?
Instead of building a large if/elseif/else block I would like
to do a case
$page in (list).
http://www.php.net/control-structures.switch
Yes, It's called SWITCH
Just go to www.php.net and lookup switch in the function list
Max Clark [EMAIL PROTECTED] wrote:Hi-
I was wondering if php had a case function?
Instead of building a large if/elseif/else block I would like to do a case
$page in (list).
Thanks in advance,
Max
--
On Thu, 19 Dec 2002, Max Clark wrote:
Hi-
I was wondering if php had a case function?
Instead of building a large if/elseif/else block I would like to do a case
$page in (list).
The documentation and search capabilities at http://www.php.net are your
frientd. It would behhove you to at
6 matches
Mail list logo