Closed dasaco closed 8 years ago
Also tried various ways of writing facade and provider in app.php, nothing works
Done composer dump-autoload and composer update
Directory exists in vendor folder, it is there
Did you reference it via \Cart or just Cart.
If you did the later make sure to include it.
use Cart;
Hello, thank you for your answer
But I tried this already, doesn't seem to work either
I'm facing this issue too, did you fix it?
hello have you found the solution to this problem
Post your source code, it is definitely working
Hello i am also facing the same issue i.e. Cart not found on server.
I've got the same issue, my friend told me that's the php version 7.0 which must be updated to at least 7.1. But the server's using 7.0
I fix this issue with include on CartController -> use Cart;
I have fixed this issue by adding in config\app.php
Provider: Gloudemans\Shoppingcart\ShoppingcartServiceProvider::class,
aliases: 'Cart' => Gloudemans\Shoppingcart\Facades\Cart::class,
in app\Http\Controller\Your-Controller-file.php
use Cart;
The package automatically registers the alias. Did you use it as \Cart
or Cart
?
https://github.com/bumbummen99/LaravelShoppingcart/issues/77
Hello,
Version: Laravel 5.2
I'm getting Class 'Cart' not found, when trying to use it in Controller, that has use Cart in it's header
In config/app.php I have both Provider and Facade
Provider: Gloudemans\Shoppingcart\ShoppingcartServiceProvider::class,
Facade: 'Cart' => Gloudemans\Shoppingcart\Facades\Cart::class,
In routes I use 'web' middleware correctly.
In composer.json I have
"require": { "php": ">=5.5.9", "laravel/framework": "5.2.", "laravelcollective/html": "5.2.", "filp/whoops": "^2.0", "gloudemans/shoppingcart": "~1.3" },
Any ideas on how to solve this issue?
Thank you
Your problem worked for me.
It's also not helpfull
Hello,
Version: Laravel 5.2
I'm getting Class 'Cart' not found, when trying to use it in Controller, that has use Cart in it's header
In config/app.php I have both Provider and Facade
Provider: Gloudemans\Shoppingcart\ShoppingcartServiceProvider::class,
Facade: 'Cart' => Gloudemans\Shoppingcart\Facades\Cart::class,
In routes I use 'web' middleware correctly.
In composer.json I have
"require": { "php": ">=5.5.9", "laravel/framework": "5.2.", "laravelcollective/html": "5.2.", "filp/whoops": "^2.0", "gloudemans/shoppingcart": "~1.3" },
Any ideas on how to solve this issue?
Thank you