Tuesday, 16 April 2019

Error: Could not find matching close tag for "<%". Following a video 'Template Engines' by NetNinja, but don't know where I have went wrong.

I got the error above, but my code I've written is the same as NetNinja's for the .ejs page.​//profile.ejs

Welcome to the profile of <%= name %>

//app.js app.get('/profile/:name', function(req, res) { const { name } = req.params res.render('profile', { name, }) }) So, when I go to a url of eg. localhost:3000/profile/mike, I get the error:Could not find matching close tag for "

No comments:

Post a Comment