I have a problem with my Laravel project. I created an admin route group (domain.co/admin/). The root /admin/ at one point was working then i added a few more pages have updated composer, installed doctrine/dbal, and installed chart.js since then. Now for some reason the /admin/ route no longer works but all other routes work perfectly normal.
my web.php routes look like this:
Route::get('/', function () { return view('home'); }); Auth::routes(); // tried commenting this out Route::middleware(['web','auth','rolecheck:Super'])->prefix('admin')- >group(function(){ Route::get('/', 'AdminController@index'); Route::get('/test', 'AdminController@index'); Route::get('/test2', 'AdminController@test'); .... }); ... There are more route groups that also work
/admin/ gives me a permission error. /admin/test/ /admin/test2/ work fine
here is the controller
namespace App\Http\Controllers; use Illuminate\Http\Request; class AdminController extends Controller { public function index(){ echo '2'; //return view('admin.dashboard'); } public function test(){ echo '1'; } } .htaccess doesnt show anything weird (default from laravel). I have also tried clearing caches.
I found nothing in the /etc/httpd conf files.
I have tired looking through all the code for the word 'admin' and can't find anything that is pointing to why its saying permission denied.
If i change the prefix to 'admins' it works so i am guessing some part of laravel is blocking the admin/ route. Where else can i look to see where its being blocked.