Build a shopping cart / Introduction

0 complete
15 parts
Next →

1. Introduction

09:17

2. Setting up

23:20

3. Braintree sandbox

05:05

4. Database

15:51

5. Product index

13:46

6. Product detail

15:50

7. Adding items

44:22

8. Cart summary

18:18

9. Updating items

10:43

10. Order form

44:28

11. Checkout

21:08

12. Braintree Drop-in UI

14:33

13. Payments with Braintree

05:26

14. Events after payment

26:46

15. Order summary

12:00

Build a shopping cart

  • 4 hours 40 mins
  • Released 2 years ago

A shopping cart with everything you'd expect. Built to be easily extendable, plus flexible payment integration with Braintree.

Discussions (9)

mamtera
2 months ago

this is not work! i want refund no respons from the admin!

mamtera
2 months ago

Warning: require(C:\xampp\htdocs\bootstrap/vendor/autoload.php): failed to open stream: No such file or directory in C:\xampp\htdocs\bootstrap\app.php on line 9

Fatal error: require(): Failed opening required 'C:\xampp\htdocs\bootstrap/vendor/autoload.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\bootstrap\app.php on line 9

frank
1 month ago

Hello. Please send your code from app.php.

Atapour
4 months ago

Parse error: syntax error, unexpected 'unset' (T_UNSET), expecting identifier (T_STRING) in /home/wolsalco/app/Support/Storage/SessionStorage.php on line 45

I have this error cause it does no work with the unset at the cart update part (checkout). I have never used unset before so if you can help me thanks !

Atapour
4 months ago

i have resolved it change unset from the function (the first unset not the one between {}) with any name like erase. Then change the interface file with erase where unset is put and after that change in Basket.php ->unset with erase

Atapour
4 months ago

So I keep getting this error from my app.php and have no clue whats going on. I will leave the error text and maybe you guys have an idea. $app = new App; This is the line with the error.

Error text :

Fatal error: Uncaught Error: Class 'Cart\App' not found in C:\xampp\htdocs\cart\bootstrap\app.php:11 Stack trace: #0 C:\xampp\htdocs\cart\public\index.php(3): require() #1 {main} thrown in C:\xampp\htdocs\cart\bootstrap\app.php on line 11

frank
4 months ago

Have you set the namespace correctly in the App.php?

Atapour
4 months ago

it has been resolved i mispelled cart

Matthew
5 months ago

So, when I try using data.token I get the following error "API Client Misconfigured: clientToken required." I'm using Laravel, so I'm doing things a little different. My script is the following:

<script>
$.ajax({
    url: 'token',
    type: 'get',
    dataType: 'json',

    success: function (data) {
       braintree.setup(data.token, 'dropin', {
         container: 'payment'
        });
     }
  });
</script>

Now, if I do use a Tokenization Key instead of a Client Token, then it works. If I do something like:

<script>
$.ajax({
    url: 'token',
    type: 'get',
    dataType: 'json',

    success: function (data) {
       console.log(data);
     }
  });
</script>

I get the following in the console:

data: token: "eyJ2ZXJzaW9uIjoyLCJhdXRob3JpemF0aW9uRmluZ2VycHJpbn…JZCI6InBxYzk3cG1ubjJua2h5NjkiLCJ2ZW5tbyI6Im9mZiJ9" proto:Object

Any ideas where I'm going wrong? I really don't want to use the Tokenization Key and would rather use the Client Token. Thanks!