【发布时间】:2017-12-02 20:00:12
【问题描述】:
路线:
$router->get('vehicle/{year}/{make}/{model}/{rating?}','VehicleController@vehicle');
控制器动作
public function vehicle($year, $make, $model, $rating = false)
{
// Implementation
}
网址 http://localhost:8080/vehicle/2010/Wapal/S2
错误
(1/1) NotFoundHttpException
事情很明显,肯定是laravel核心的bug吧?为什么会出现这个错误?
【问题讨论】:
-
尝试将您的路线更改为 Route::get('vehicle/{year}/{make}/{model}/{rating?}','VehicleController@vehicle');