In my Node.js application, I have a function (routed by Express) which presents a form to the user:
app.get(\'/register\', function (req, res) { res.render
You need to use flash notifications, and it is built into express.
You'll add a message like so: req.flash("error", "Invalid form...");
req.flash("error", "Invalid form...");
You'll need a dynamic handler to add the messages to your rendered template, or you can check out the ones TJ has made for express. (express-messages)