Checking a
Checking a
 
if (! array_key_exists($_POST['order'], $GLOBALS['sweets'])) {
    $errors[] 'Please choose a valid order.';
}
  
  
Related examples in the same category
1. Checking for an element with a particular key
2. Validating a drop-down menu with array_key_exists()
3. Testing for the Existence of a Key in an Array
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.