Best Form Validation library for Slim


I am using Slim 3 for Rest Api, and i need to validate data coming from frontend like not empty, number, email…
Please suggest me any easy to use library for this.


These are both popular, I use vlucas/valitron in many of my projects.


I use -


PHP has built in functions:

not empty => !empty($var)
number => is_numeric($var) or is_int($var) or is_float($var)
is email: filter_var($email, FILTER_VALIDATE_EMAIL) !== false


Thanks for your reply, i will try vlucas/valitron :slight_smile:


maybe you like this :