A quick and easy to use utility to validate all sorts of data for your PHP website. All validation methods are static thus dramatically improving validation speed and performance: Validation Features Include: Is Alphanumeric Value Is Alpha Value Is Upper Case String Is Numeric Value Is Floating Point Value Is Date/Time String Is Email String Is Phone Number String Is UTF8 String Is Social Security Number Is Valid URL Is Valid Existing URL Is a Hex Color Code Is an RGB Color Code Is a Number between 2 numbers Is an array of unique elements Is a valid File Is a file below a max file size below max size Easy Code Setup and Usage: Set Up require ‘DataValidator
A quick and easy to use utility to validate all sorts of data for your PHP website. All validation methods are static thus dramatically improving validation speed and performance:
Validation Features Include:
- Is Alphanumeric Value
- Is Alpha Value
- Is Upper Case String
- Is Numeric Value
- Is Floating Point Value
- Is Date/Time String
- Is Email String
- Is Phone Number String
- Is UTF8 String
- Is Social Security Number
- Is Valid URL
- Is Valid Existing URL
- Is a Hex Color Code
- Is an RGB Color Code
- Is a Number between 2 numbers
- Is an array of unique elements
- Is a valid File
- Is a file below a max file size below max size
Easy Code Setup and Usage:
Set Up
require ‘DataValidator.php’;
Validate Alpha Numeric String
DataValidator::isAlphaNumeric(‘foobar123’);
Validate Hexadecimal Color Code
DataValidator::isHexColor(’#010101’);
Validate Email Address
DataValidator::isEmail(‘abc@foo.com‘);
Validate File Size
DataValidator::isBelowMaxFileSize(’./foo.php’, 23);
No comments:
Post a Comment