Home  >  Article  >  Backend Development  >  Laravel 5.1 更改默认登录跳转路径

Laravel 5.1 更改默认登录跳转路径

WBOY
WBOYOriginal
2016-06-23 13:23:561291browse

Laravel 5.1默认登录后台后会跳转到/home路径,现在需要更改当用户登录成功后跳转到 /admin下,只需要改下AuthController.php 增加个$redirectPath属性就OK了。和之前Laravel 5.1 使用用户名登陆很相像.

protected $redirectPath = '/admin';
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn