Skip to content

Commit

Permalink
Customize confirm() and alert() a bit
Browse files Browse the repository at this point in the history
  • Loading branch information
apankrat committed Aug 10, 2022
1 parent a456a76 commit c05defb
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions nullboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -1698,6 +1698,15 @@ <h3>Auto-backup</h3>
return Math.min(Math.max(this, min), max);
};

/*
* add a blank line to push 'Prevent this page from opening ...'
* tack-on from the actual message we are trying to display
*/
var confirm_org = window.confirm;
var alert_org = window.alert;
window.confirm = function(msg) { return confirm_org(msg + "\n "); }
window.alert = function(msg) { return alert_org (msg + "\n "); }

</script>

<script type="text/javascript">
Expand Down

0 comments on commit c05defb

Please sign in to comment.