Home > Enterprise >  send a message while redirecting
send a message while redirecting

Time:06-06

hello please I want to send a message while redirecting but I got an error

let message = "An error ocoured while updating user record to ahow verified."
res.redirect(`/verified/error=true&message=${message}`)

this is the route

app.get("/verified", (req, res) => {
  res.render("auth-verified-email");
})

error

Cannot GET /verified/error=true&message=Link has expired .Please sign up again

CodePudding user response:

Try this :

app.get("/verified/:params", (req, res) => {
  res.render("auth-verified-email");
})
  • Related