[Solved] NotFoundHttpException in RouteCollection.php (line 179) in Laravel 5.4

Hello I am facing NotFoundHttpException error when i access /login or /register
when i run the php artisan make:auth command, routes are also created their, but /login or /register is not working for me, let me share my code with you.

Web.php

Auth::routes();
Route::get('/home', '[email protected]')->name('home');

when i check my browers concole its showing this error

GET http://localhost/laravel5authprc/login 404 (Not Found)

Solution #1:

Try to access http://localhost/laravel5authprc/index.php/login
If it works, then you need to set up a virtual Host in your apache vHosts file

Respondent: Sletheren

Solution #2:

Probably something is NotFoundHttp

I’d recommend:

Try:

Route::group([ 'prefix' => 'laravel5authprc' ], function () {

Auth::routes();
Route::get('/home', '[email protected]')->name('home');
Route::get('/', '[email protected]')->name('home.alias');


});
Respondent: ???? ??

The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Leave a Reply

Your email address will not be published.