![](/img/trans.png)
[英]Error "Sorry, the page you are looking for could not be found." Laravel 5.5
[英]Sorry the page you're looking could not be found. Laravel 5.5
我有laravel 5.5。 一切工作正常。 我可以訪問所有路線。 但是我無法以某種方式訪問路由“ / interest / {$ id}”。
這是我的路線。
<?php
Route::get('/interest/{$id}', [
'uses' => 'IdeaController@createInterest'
])->name('interest.create')->middleware('auth');
我可以訪問每條路線接受此路線。 我希望這有幫助。
從您的route參數中刪除美元符號:
Route::get('/interest/{id}', [
'uses' => 'IdeaController@createInterest'
])->name('interest.create')->middleware('auth');
Route::get('/interest/{id}', [
'uses' => 'IdeaController@createInterest'
])->name('interest.create')->middleware('auth');
//in controller use method
public function createInterest($id){
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.