Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

275
Views
Cannot GET page in an ejs file

I am trying to open a new file when someone clicks on the "Lets edit stuff" button but I get the error Cannot GET /edit.ejs

Both of these files are in the same folder off views/pages/ but I keep getting this error. I have the server.js file running from node.

<body class="container">
    <main>
        <ul class="nav nav-pills nav-fill">
            <li class="nav-item">
              <a class="nav-link active" aria-current="page" href="#">Homepage</a>
            </li>
            <li class="nav-item">
              <a class="nav-link" href="edit.ejs">Lets edit stuff</a>
            </li>
            <li class="nav-item">
              <a class="nav-link" href="#">Link</a>
            </li>
          </ul>

This is what I see on the page

Cannot GET /edit.ejs
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I found that the problem was I did not have a app.get for edit so I had to add

app.get('/edit', function(req, res) {
    res.render('pages/edit');
});

in my server.js file

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!