> craig <mailto:[EMAIL PROTECTED]>
on Friday, February 06, 2004 2:24 PM said:
if (is_array($project)) foreach ($project as $project_id => $value) { $fields[] = $project_id; $values[] = $value; } }
you're missing a curly brace after the if ().
my bad, that's what you get when you don't actually run the code. Thank god for compilers ;)
You'll still get the notice message with is_array(), though. Use isset().
if(isset($project))
or
if(isset($project) && is_array($project))
-- ---John Holmes...
Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
php|architect: The Magazine for PHP Professionals – www.phparch.com
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php