expValidator

define

"BASE" "../../.."

package

Subsystems

Methods

Checks if object field is set (boolean true)

acceptance_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains an alphanumeric value

alphanumericality_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks validity of recaptcha antispam entry

check_antispam( $params, string $msg = "") : boolean
static

Arguments

$params

$msg

string

Response

boolean

Method to determine password strength e.g., not correct type/number of characters

checkPasswordStrength( $password) : string
static

Arguments

$password

Response

string

error if any

Routine to check that username is valid (longer than 3 characters)

checkUsername( $username) : string
static

Arguments

$username

Response

string

confirmation_of

confirmation_of( $field,  $object,  $opts) 
static

Arguments

$field

$object

$opts

Routine to note error and return to the filled out form with messages

failAndReturnToForm(string $msg = '', null $post = null) 
static

Arguments

$msg

string

$post

null

Routine to error and return to the filled out form with flash message

flashAndReturnToForm(string $queue = 'message',  $msg, null $post = null) 
static

Arguments

$queue

string

$msg

$post

null

format_of

format_of( $field,  $object,  $opts) 
static

Arguments

$field

$object

$opts

Generate a random secure password

generatePassword(string $len = MIN_PWD_LEN, string $cap = MIN_UPPER, string $num = MIN_DIGITS, string $sym = MIN_SYMBOL) : string
static

Arguments

$len

string

$cap

string

$num

string

$sym

string

Response

string

Checks if object field contains a valude email address

is_valid_email( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains a valid phone number

is_valid_phonenumber( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains a valid sef name

is_valid_sef_name( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains a valid state abbreviation

is_valid_state( $field,  $object,  $opts) : boolean|string
static

Arguments

$field

$object

$opts

Response

boolean|string

Checks if object files contains a valid zipcode

is_valid_zipcode( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Validate an email address.

isValidEmail( $email) : boolean
static

Provide email address (raw input) Returns true if the email address has the email address format and the domain exists.

Arguments

$email

Response

boolean

Checks if object field is minimum length

length_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains an numeric value

numericality_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Checks if object field contains a value (not empty)

presence_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Routine to mark which form field had the error

setErrorField( $field) 
static

Arguments

$field

Check for uniqueness of object field amongst all items in table

uniqueness_of( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed

Determines if upload was successfully inserted into 'file' table

uploadSuccessful( $file) : mixed
static
deprecated

Arguments

$file

Response

mixed

All purpose validation method

validate( $vars,  $post) : boolean
static

Arguments

$vars

$post

Response

boolean

Wrapper function to validate email address

validate_email_address( $email) : boolean
static

Arguments

$email

Response

boolean

Checks if object field value is between two limits

value_between( $field,  $object,  $opts) : mixed
static

Arguments

$field

$object

$opts

Response

mixed