My front sends parameters in the url and I would like to get them back to my laravel controller.
My route (back)
Route::get('publication/Mls/{status}/{typeTransac}', 'MlsController@getIndicatorMlsList');
The console shows me this on the front side
api/user/publication/Mls?status=Archive&typeTransac=Vente
How do I get this information back?
they are not the same route. you have to change either in front end or back end. the front end url is
in this url
api/user/publication/Mlsis the base url and?status=Archive&typeTransac=Venteis request parameter. to get it in the laravel side you need a route likeassuming you have
userprefixed in your route. if not you have to add that too in your route.now in your controller you can access the request parameter
or you can keep your back end route as same as it is now and change the front end url
and in the controller