SproutCMS

This is the code documentation for the SproutCMS project

function allInArray()

Checks each value of an array is one of the allowed values

Usage

void Validity::allInArray ( array $val , array $allowed );

Example

$_POST['vowels'] = ['a', 'i']
$valid->check('vowel', 'Validity::allInArray', ['a', 'e', 'i', 'o', 'u'])

Arguments

  1. array $val
  2. array $allowed

Exceptions thrown

Return value

  • void