The use statement with non-compound name 'DB' has no effect
Created at 24-Sep-2021 ,
By samar
I have found error The use statement with non-compound name 'DB' has no effect in Laravel. To remove the error we have to just remove the use DB; statement from routes\web.php file
-
Remove use DB; statement from routes\web.php
//Remove below code from route\web.php use DB;
If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.
Don't forget to share this article! Help us spread the word by clicking the share button below.
We appreciate your support and are committed to providing you valuable and informative content.
We are thankful for your never ending support.
Random Code Snippet Queries: Laravel
- Remove public from url in laravel project
- Add class to body in laravel view
- Insert data with form validation using ajax in laravel
- Redirect from www to non www in laravel using htaccess
- Laravel append URI in route
- Display option of select as selected with blade directive Laravel
- Attempt to read property "avatar" on null in Laravel
- How to create and run user seeder in laravel
- If condition in Laravel 9
- Create project factory and seed data in laravel
- First and last item of the array using foreach iteration in laravel blade
- Get 30 days older records from table in laravel
- Send OTP using textlocal api in laravel
- Illuminate\Database\QueryException could not find driver
- Rename Pivot Table in Laravel
- Get Array of IDs from Eloquent Collection
- Laravel onclick function not working
- How to update record after save method in Laravel
- Create record with unique slug in laravel
- How to pass external link in laravel blade to anchor tag
- Call to a member function getRelationExistenceQuery() on array in Laravel
- How to get file extension from input type file in laravel
- Get the products list ordered by a user
- How to get count of all records created at yesterday
- How to create laravel project using composer