Info Panel
Roll it!   ⇔
1 - Documantation
* Knowledge Base
  • Mvc
  • Application
  • Advanced
  • Operators
  • Api
* Origin Template
  • Customize
* Core Classes
* Classes

* all grey titles exists but not documented yet

Validator

Type: core

Class: Validation

Platform: 2v

Function: validator

Visibility: public

Parameter: validator($string,$type)

Description:
Validates a string with selected type of test.
Parameters:
(optional) - string - $string - The string to validate.
(optional) - string - $type - The type of test we want to run on the $string, such as: any kind of integer / varchar / characters / filename / url / email / ip / date / xss check.
Return:
string - The string after the validation - If test was negative, the string will be wiped, unless we chose: varchar / xss - It will return the filtered value of string.
Callable from (extended classes):
application: controller,view
advanced: controller,view
operators: controller,view
api: controller,view
example: 1
Let's validate a string.
How to call (example):
Code:
Possible outcome (example):
Output:
Info Panel
Roll it!   ⇔