A
A
Alexander Bondarenko2020-07-07 18:06:51
Django
Alexander Bondarenko, 2020-07-07 18:06:51

How to create a cart in django without going to other pages?

How can I make a basket with sessions in django so that when adding a product, do not follow the link? I found an implementation here https://pocoz.gitbooks.io/django-v-primerah/glava-... , but here the cart goes on a separate page, but I need it on one page. Please tell me the algorithm or where you can read something, thanks!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrew, 2020-07-07
@bond_1013

Store cart items in localStorage on the front,
then send with AJAX to the back.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question