Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
尝试通过验证检查错误路由回页面。这不起作用,这样做的正确方法是什么?
$route = "staff/" . $staff->staff_id; return Redirect::to_route($route) ->with_errors($validation);
你可以试试这个重定向回来(假设 Laravel 3)
return Redirect::back()->with_errors($validation);
或者这个
return Redirect::back()->with_errors($validation)->with_input();
因此,无需提及路线,这是在我的一个项目中测试的。