0
votes

Error says

all to undefined function group()

at C:\laragon\www\OnlineComplianceManagement\routes\web.php:32 28| return view('loginblade'); 29| // Route::get('/index','Modules/Login/Http/Controllers/LoginController@index'); 30| }); 31|

32| Route:group(['middleware'=>['web']],function(){ 33| //Route::get('login/index','LoginController@index'); 34| Route::get('LoginModel', 'MainLoginController@index'); 35|
36| });

1 C:\laragon\www\OnlineComplianceManagement\vendor\laravel\framework\src\Illuminate\Routing\RouteFileRegistrar.php:35 require()

2 C:\laragon\www\OnlineComplianceManagement\vendor\laravel\framework\src\Illuminate\Routing\Router.php:417
Illuminate\Routing\RouteFileRegistrar::register("C:\laragon\www\OnlineComplianceManagement\routes/web.php")

my code

Route:group(['middleware'=>['web']],function(){     
        Route::get('LoginModel', 'MainLoginController@index');   
  });
2

2 Answers

1
votes

You have misspelled on : (colon) , Should be :: (double colon) :

Route::group(['middleware'=>['web']],function(){     
   Route::get('LoginModel', 'MainLoginController@index');   
});
0
votes

Perhaps you are not using routes in api.php and web.php Try to write use

use Illuminate\Support\Facades\Route;

Route::group(['middleware' => ['web']], static function () {
    Route::get('LoginModel', 'MainLoginController@index');
}

Another way

Route::middleware(['web'])->group(static function () {
    Route::get('LoginModel', 'MainLoginController@index');
});