When I use foreach on a uninitialized array I get the following warning:

Warning:  Invalid argument supplied for foreach() in 
/www/htdocs/jc/cart/add_item.php on line 21

I would expect foreach to treat an unitialized variable as an empty 
array and hence do nothing. Is this the expected behaviour?

Thanks,

Jc


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

Reply via email to