1
我目前在我的管理請求頁面,網址爲wwww.website.com/requests/manage/
。我想回重定向到使用<a href="dashboard">dashborad</a>
我的儀表板頁面,但是當我點擊我的儀表盤鏈接,則網址www.website.com/requests/manage/dashboard
,而不是www.website.com/dashboard
Laravel 5.1 - 重定向回基本網址
是代碼回到我的儀表板頁面,
<td style="line-height:12pt; height:10px;">
<a href="dashboard"><b class="brandname">
dashboard</b>
</a>
</td>
這是我的routes.php文件。
Route::group(['middleware' => 'auth'], function() {
Route::get('dashboard', '[email protected]');
// All about buyer request...
Route::post('requests/success', '[email protected]');
Route::post('request/success', '[email protected]');
Route::get('requests/new', '[email protected]');
Route::get('request/new', '[email protected]');
Route::get('requests/manage/{status?}', '[email protected]');
});
是我的嘗試是增加另一個路線(見下文)來解決這個問題,但我認爲是不是一個完美的解決方案。有什麼建議麼?
Route::get('requests/manage/dashboard', '[email protected]');
它的工作!謝謝。 –