skip to Main Content

Route 404 in laravel11. Is there any rule to prioritize route in web.php

My issue is, even if I added route in web.php then also it gives me 404 not found. My route file as below. <?php use IlluminateSupportFacadesRoute; use AppHttpControllersStudentController; Route::get('/students', [StudentController::class, 'index'])->name('students.index'); Route::get('students/export/excel', [StudentController::class, 'exportExcel'])->name('students.export.excel'); Route::get('students/export/pdf', [StudentController::class, 'exportPdf'])->name('students.export.pdf'); Route::get('students/{student}', [StudentController::class, 'show'])->name('students.show');…

VIEW QUESTION

Routing issues in Laravel project

I am working on a Laravel project where I have three types of admins, each with their own login pages. Here are the routes: // Core Admin Routes Route::get('/core-admin', [CoreAuthController::class, 'loadLogin']); Route::post('/core-admin', [CoreAuthController::class, 'login'])->name('login'); Route::middleware('auth')->group(function () { Route::get('/core-admin/dashboard', [CoreAuthController::class, 'coreAdmin']);…

VIEW QUESTION

Php – Laravel 8 prefix on route not working when placed and url works with prefix if its not on code

I have a routes folder admin.php, with following intended code Route::prefix('admin')->group(function(){ Route::get('/new/dashboard',[SuperAdminController::class,'dashboard']); Route::get('/new/notifications', [SuperAdminController::class,'notifications']); }); But if i go on the browser and use http://127.0.0.1:8000/admin/new/dashboard i get 404 | page not found. But if remove the prefix and the code…

VIEW QUESTION

Laravel route model binding for model with uuid does not instantiate model

I've run out of ideas so I thought I'll ask around - here's my code: # app/Map/MapServiceProvider.php class MapServiceProvider extends ServiceProvider { /** * Bootstrap any package services. */ public function boot(): void { Route::model('map_marker', Marker::class); $this->loadMigrationsFrom(__DIR__.'/Migrations'); $this->loadRoutesFrom(__DIR__.'/routes.php'); } //…

VIEW QUESTION
Back To Top
Search