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

203
Views
Temporarily disabling javascript alerts from a certain page?

I'm making code edits to my website within cPanel's file manager. With the latest update of cPanel v.104, after saving my file, control+Z does not revert my changes.

Now, A javascript alert pops up asking: "Are you sure you want to save? The file will be overwritten."

I hypothesize that a redefinition of the alert function, locally via my javascript console could stop this behavior and thus reclaim my control+Z ability.

window.alert = function() {};

Well, this does successfully disable alerts when I throw it in the console. Is it incorrect methodology to paste this in the console? Is there something else I should do?

Here is a thread tracking this issue: https://forums.cpanel.net/threads/cpanel-40934-website-com-says-are-you-sure-you-want-to-save-the-file-will-be-overwritten.701853/

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

0

Alert box is used to provide the user some information. When trying to receive approval or disapproval, confirm() is used.

Try pasting this code in your web dev tools console.

window.confirm = function() {};
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!