简体   繁体   中英

Laravel cannot route to /admin

I'm starting a new project with Laravel 5.7. I've made standard laravel Auth with artisan. It registered a new route in routes/web.php which is

Route::get('/home', 'HomeController@index')->name('home');

The problem is when i rename '/home' to '/admin' it doesn't work. It returns ' The requested resource /admin was not found on this server. ' error. I can replace '/home' with anything except '/admin'. Anything else works without a problem. What is wrong with '/admin' and why can't i use '/admin' as a route?

You can't use this '/admin' route because your project may have 'admin' folder (but not listing file due server config). Simply rename your admin folder or use '/admin/home' instead.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM