I want make a post request and then take the response and update the DOM without a page load. Do I need to make an AJAX call within my app, or is there a node way to do this?For example//view .form(action="/api" method="POST" input(type="submit" value="Send some data" #return_value // put response in here // router router.post("/api", function(req, res, next) { res.send(data) } Then in my view update using the data above.
Submitted December 31, 2016 at 01:36PM by pm_me_gold_plz
No comments:
Post a Comment