-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On September 11, 2002 15:57, Kevin Stone wrote:
> Really quick question. Will "return" break a loop inside a function?
>
> Example..
> myfunc()
> {
> while($val=0)
> {
> if ($i=128)
> {
> return true; //<-break or no?
> }
> }
> }
>
> I know I could easily figure this out my own but I do not have the means to
> test it right now. :)
Yes - return will break a loop.
Cheers!
- --zak
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQE9f74qb6QONwsK8bIRAl+hAJwI4VaBj6IYtbjgHxGQkmq+Lg2iggCfYqOT
gsTebidZ6s5u2tc5SC60IyM=
=bywU
-----END PGP SIGNATURE-----
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php