Closed tenmajkl closed 1 year ago
This PR adds error messages to validation, meaning that now, when validation error ocures, instead of just saying "Bad data" you get better errors. So if we pass request
foo=bar
into this validation
$r->validate([ 'foo' => 'numeric', ], template('foo'));
with this template
{ ifError } <div class="error"> { error } </div> { /ifError }
response would be div with class error and message Value foo must be numeric.
Value foo must be numeric.
All the error messages are from translations.
Resolves #112
This PR adds error messages to validation, meaning that now, when validation error ocures, instead of just saying "Bad data" you get better errors. So if we pass request
into this validation
with this template
response would be div with class error and message
Value foo must be numeric.
All the error messages are from translations.
Resolves #112