Answer the question
In order to leave comments, you need to log in
How to authorize via JS (XHR, Fetch)?
For example, there is a server that sends JSON {success: true} if the log/pass is correct and {success: false} if not.
This form authorizes the user when posting to login :
form(id="login-form", method="post", action="/login")
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question