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

154
Views
Javascript function is not get called (onclick => function name)

My javascript function is not get called , but it get called when i open the console window by inspect->console

when this was opened ,on that time , my javascript onclick function was getting called perfectly and my code on that function gets executed

but without opening my console log tab (inspect->console) , on that case it is not getting called

my code:


<%= form.check_box 'active', :class=>"icheck", :"data-checkbox" => "icheck_val_box", :onclick =>"clickfun()" %>
<%= form.label 'active', 'mybooklib'%>

the function



function clickfun(){
$("#savebookicon").attr("disabled",true);
});

but this clickfun funciton is only working if my console log window was opened,

this was new kind of error to me, i didnt came accross this kind of error so can anyone help meout?

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!