Custom validator in Laravel 5
Try the following: Make a bind class where you can implement each rule you want extending Validator class. Make a service provider that extends ServiceProvider. Add your custom validator provider at config/app.php file. You can create the bind at Services folder like this: namespace MyApp\Services; class Validator extends \Illuminate\Validation\Validator{ public function validateFoo($attribute, $value, $parameters){ return … Read more