[Phpwm] updating an array
Rob Allen
rob at akrabat.com
Fri Oct 20 13:18:22 BST 2006
alan dunn wrote:
> Rob, thank you for the suggestion of using in_array. After a frustrating
> couple of hours I found that in_array looks for a match on the array
> element value, not the array key value. So then I tried to set up a two
> dimensional array and tried to run in_array on that. I don't think
> in_array runs against multi-dimension arrays (am I wrong?).
>
As David pointed out, I meant array_key_exists.
Just moving the initialisation of $match from the inner foreach() should
also solve the problem.
Sorry.
Regards,
Rob...
More information about the Phpwm
mailing list