SproutCMS

This is the code documentation for the SproutCMS project

function range()

Checks that a value is numeric (integral or decimal) and within a given inclusive range

Usage

void Validity::range ( string $val , number $min , number $max );

Example

$valid->check('cost', 'Validity::range', 0, 5000)

Arguments

  1. string $val
  2. number $min
    The minimum the value may be
  3. number $max
    The maximum the value may be

Exceptions thrown

Return value

  • void