3
In the Laravel have for example:
Route::get( '/produtos/mostra/{id}',
'ProdutoController@mostra'
)->where('id', '[0-9]+');
How this kind of validation would be done in the Lumen? Given that a route is originated by $app
:
$app->get('insert', function () {
});
It didn’t work to put the
where
in the end too ?– Diego Souza
@Zooboomafoo no, makes the mistake:
Call to undefined method Laravel\Lumen\Application::where()
– Leonardo
But you have to be negative ? I’m trying to help you.
– Diego Souza
@Zooboomafoo It is because with almost 10K of reputation you should know that the answer field was not made to debate the question, for that there are comments. As much as I want to help, I have to follow the rules here. With the edition you made worked, I’ll put +1, thanks, and I hope you understand why the negative before.
– Leonardo