FloatType
Validates whether the type of the input is float.
v::floatType()->assert(1.5);
// Validation passes successfully
v::floatType()->assert('1.5');
// → "1.5" must be a float
v::floatType()->assert(0e5);
// Validation passes successfully
Templates
FloatType::TEMPLATE_STANDARD
| Mode |
Template |
default |
{{subject}} must be a float |
inverted |
{{subject}} must not be a float |
Template placeholders
| Placeholder |
Description |
subject |
The validated input or the custom validator name (if specified). |
Categorization
Changelog
| Version |
Description |
| 3.0.0 |
Templates changed |
| 1.0.0 |
Created |
See Also