【发布时间】:2021-03-22 15:58:36
【问题描述】:
如何更改提交表单时生成的 URL
http://localhost:8000/list_entreprise?activity=3&sub_category=1§eur=1&page=2
到这个网址:
http://localhost:8000/list_entreprise/category_name/sub_category_name/secteur_name/2
需要使 URL 对搜索引擎更友好。
我从表单中的选择字段中获取 category、sub_category 和 secteur
http://localhost:8000/list_entreprise
我的路线:
Route::get('/list_entreprise','App\Http\Controllers\SiteController@search')->name('search');
【问题讨论】: