Re: explode question

From: Date: Wed, 07 Mar 2001 18:16:26 +0000
Subject: Re: explode question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-42919@lists.php.net to get a copy of this message
Rol wrote: > > Hello all, > > I would like to check some names ( @ seperated strings) with this global $PHP_AUTH_USER > > I first do > $arrLoginName = explode("@", $row->usr_loginName); > > How can I construct a loop which stops and returns true if a match is found? > > Any hints would be great. > > Many thanks > > Roland This will do it: $dim = sizeof($arrLoginName); for ($nr = 0; $nr < $dim; $nr++) { if (match) { return 1; } } Greetings, Jason -- Jason Murray Developer http://www.jwebmedia.com/ 1 877 525 jWEB

« previous php.general (#42919) next »