0
votes

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?

1
Check if there is folder name as admin under your public directory. - Iftikhar uddin
Yes, problem is definitely an admin folder under public folder. Is there a way to force laravel ignore folder structure and only use route rules? - megavolkan
You cant ignore folders, think of css and js folders. If you want to ignore admin folder you have to edit the .htacces file, but that's another question. - dparoli

1 Answers

2
votes

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.