Re: Array

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Aug 10, 2009 at 9:28 AM, Ron
Piggott<ron.piggott@xxxxxxxxxxxxxxxxxx> wrote:
> How do I change this ELSEIF into an array?
>
> } elseif ( ( $page <> "" ) AND ( $page <> "home_page" ) AND ( $page <> "verse_of_the_day_activate" ) AND ( $page <> "member_services" ) AND ( $page <> "member_services_login" ) AND ( $page <> "member_services_logoff" ) AND ( $page <> "resource_center" ) AND ( $page <> "network" ) ) {

Something like:

} elseif (!in_array($page, array("", "home_page",
"verse_of_the_day_activate", ...))) {

should work.

Regards,

Jonathan

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux