Releases: Octagon-simon/octaValidate-PHP
Releases · Octagon-simon/octaValidate-PHP
octaValidate-PHP V2.1
validateFields()
method accepts 2 arguments.
- The first argument is an array of your validation rules
- The second argument is the
array
of the fields to validate.- This is where the form fields are coming from which can either be the
$_POST
or$_GET
array. If no value is provided, it defaults to the$_POST
array.
- This is where the form fields are coming from which can either be the
-
status()
method was removed -
All public methods now have better documentation on how to invoke them
octaValidate-PHP V2.0
- The helper script was modified to remove errors when an input element contains a value
- We removed
validate()
method to addvalidateFields()
&validateFiles()
methods. Visit the documentation to learn more about these methods
octaValidate-PHP V1.6
- Marked the method
validate()
as deprecated - If strict mode is enabled, the library now returns a message containing the words that are not allowed.
octaValidate-PHP V1.4
- Fixed a bug
- Files are now being validated with or without the required rule
octaValidate-PHP V1.2
Removed json_encode
on getErrors() method, so that it will be used directly on your PHP script.
if( $myForm -> validate($valRules) ){
//process form data here
}else{
//instead of doing this
print_r( $myForm -> getErrors() );
//do this instead
print_r( json_encode($myForm -> getErrors()) );
}
octaValidate-PHP V1.1
Replaced Email Validation to use PHP's inbuilt filter_var()
validation
octaValidate-PHP V1.0
First official release. Please visit the documentation to learn more about this Library