Method |
Description |
|
init ( ) |
|
|
rule_after ( $a ) |
Checks any PHP datetime format:
http://www.php.net/manual/en/datetime.formats.date.php. |
|
rule_alpha ( $a ) |
Test for A-Za-z. |
|
rule_alphanum ( $a ) |
Test for A-Za-z0-9. |
|
rule_before ( $a ) |
Checks any PHP datetime format:
http://www.php.net/manual/en/datetime.formats.date.php. |
|
rule_between ( $a ) |
Inclusive range check. |
|
rule_bool ( $a ) |
Validate for true|false|t|f|1|0|yes|no|y|n. |
|
rule_card_from_date ( $a ) |
Validate a card "valid from" date. |
|
rule_card_to_date ( $a ) |
Validate a card "expires end" date. |
|
rule_class ( $a ) |
|
|
rule_credit_card ( $a ) |
Validate for credit card number. |
|
rule_decimal ( $a ) |
|
|
rule_decimal_places ( $a ) |
Checks for a specific number of
decimal places. |
|
rule_email ( $a ) |
* \section Value Test Rules: Postal, Email & Credit Card |
|
rule_eq ( $a ) |
|
|
rule_eqf ( $a ) |
|
|
rule_false ( $a ) |
Validate for false|f|0|no|n. |
|
rule_gt ( $a ) |
|
|
rule_gte ( $a ) |
|
|
rule_in ( $a ) |
Checks that value is in the list provided. |
|
rule_int ( $a ) |
|
|
rule_iso_datetime ( $a ) |
Validate ISO datetime in the format:. |
|
rule_iso_time ( $a ) |
Validate for ISO time. |
|
rule_len ( $a ) |
|
|
rule_lt ( $a ) |
|
|
rule_lte ( $a ) |
|
|
rule_not_in ( $a ) |
Checks that value is not in the list provided. |
|
rule_number ( $a ) |
Checks for int or float. |
|
rule_phone ( $a ) |
|
|
rule_regex ( $a ) |
Requires a regex pattern as the
next rule in the chain. |
|
rule_required ( $a ) |
* \section Value Test Rules: General |
|
rule_to_add_slashes ( $a ) |
|
|
rule_to_alpha ( $a ) |
Strip to A-Za-z0-9. |
|
rule_to_alpha_num ( $a ) |
|
|
rule_to_alpha_num_dash ( $a ) |
|
|
rule_to_alpha_num_dash_unicode ( $a ) |
Strip to unicode letter characters and 0-9, -, _. |
|
rule_to_alpha_num_unicode ( $a ) |
Strip to unicode letter characters and 0-9. |
|
rule_to_alpha_unicode ( $a ) |
Test for unicode letter characters. |
|
rule_to_digits_and_single_spaces ( $a ) |
|
|
rule_to_float ( $a ) |
|
|
rule_to_int ( $a ) |
* \section Value Conversion Rules: Numeric |
|
rule_to_iso_date ( $a ) |
* \section Value Conversion Rules: Date & Time |
|
rule_to_lower ( $a ) |
|
|
rule_to_ltrim ( $a ) |
|
|
rule_to_name ( $name, $is_capitalise_prefix = false ) |
Useful for cleaning up input where you don't want to present
an error to the user - eg a checkout where ease of use is
more important than accuracy. Can save a lot of re-keying. |
|
rule_to_number ( $a ) |
|
|
rule_to_quote_meta ( $a ) |
|
|
rule_to_rtrim ( $a ) |
|
|
rule_to_strip_extra_space ( $a ) |
Reduce sequential whitespaces to a single space. |
|
rule_to_strip_nasties ( $a ) |
Strip out attack characters from names & addresses
and other strings where they have no place. |
|
rule_to_strip_slashes ( $a ) |
|
|
rule_to_strip_space ( $a ) |
Strip out all white space. |
|
rule_to_strip_tags ( $a ) |
* \section Value Conversion Rules: Data Sanitization |
|
rule_to_trim ( $a ) |
* \section Value Conversion Rules: String |
|
rule_to_truncate ( $a ) |
Truncates, and adds '. |
|
rule_to_truncate_custom ( $a ) |
Requires parameters: length,
custom string to end of string. |
|
rule_to_upper ( $a ) |
|
|
rule_to_upper_words ( $a ) |
|
|
rule_to_zip ( $a ) |
Normalizes, then validates. |
|
rule_true ( $a ) |
Validate for true|t|1|yes|y. |
|
rule_type ( $a ) |
|
|
rule_zip ( $a ) |
Checks for a 5 digit or extended US zip. |
|
to_strip_regex ( $a ) |
Strips out the characters matched by the
pattern in the argument. |
|
validate_iso_date ( $a ) |
Validate for ISO date in format YYYY-MM-DD. |
|