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

196
Views
Basic JavaScript/JQuery Function Not Working for No Reason

My teammate and I have been tirelessly working at this seemingly impossible bug with js/jquery. We have a simple function called feedback in our .js file, but it is not working. See our replit link below:

https://replit.com/join/pryxsdvjtz-5pengoo

Please help.

Edit: Here's the function:

function feedback(event) {
  event.preventDefault();
  console.log("this function ran");
  var text = $('#text');
  console.log(text);
}

I've reduced a lot of its functionality for debugging purposes but all I want it to do is print "this function ran" in the console. Thank you!

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

This is because I think, replit is not redirecting to create.html which you can verify from the url in the mini browser window. I feel this is how the replIt works. Whereas, if you tried in new tab you can see create.html in the url as a path. If the create.html is not loaded, then your script is also not loaded right. So, your function is not executed.

In the top right corner of the browser preview window in replit there is one option for opening the url in new tab. The code you posted works there. It is not working in the preview-browser-window. So there is nothing wrong with your code.

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!