S
S
Sergey Nizhny Novgorod2016-06-24 18:57:53
JavaScript
Sergey Nizhny Novgorod, 2016-06-24 18:57:53

How to do ajax in Django?

Hello.
The task is as follows:
1) the user clicks on the comment like button on the page.
2) The number of likes increases by +1
3) This user is registered in the model of likes (so that he cannot add them anymore).
4) In the model of the author of the comment, +1 is added to the overall rating on the resource.
And all this must be done without reloading the page and without losing the user's focus.
I honestly have not worked with ajax yet (I ran it when I studied js) and technologies like angular, react, action script, etc. The question is: what to choose to implement my logic, + what is suitable for further expanding the functionality without reloading the page.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
V
Vyacheslav, 2016-06-24
@Terras

Choose ajax, that's it.

P
Postalus, 2016-06-25
@Postalus

In pure javascript.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question