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

89
Views
Form keeps loading in nodeJs

I have a form that just takes two inputs, which are then passed to the /addpost-disabled endpoint, and inserted into the SQL test database. It runs fine but it keeps loading, what would be an easy fix?

ps. I removed the connection.end() method as it triggered an error and I could only add input once.

    app.post('/addpost-disabled', urlencodedParser, (req, res) => {
        console.log('backend got an api endpoit hit');
        console.log('starting query')
        connection.query(`insert into test(title, description) values (?, ?)`, 
            [req.body.postTitle, req.body.postDescr],
            (error, results) => {
                if(error) console.log(error);
                console.log('inserted these values into test database')
                console.log(req.body.postTitle);
                console.log(req.body.postDescr);
                console.log('ending connection');
            } 
        )
    })
about 4 years ago · Juan Pablo Isaza
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!