Warn/confirm User if Back button is Pressed is as below.
window.onbeforeunload = function() { return "Your work will be lost."; };
You can get more information using below mentioned links.
Disable Back Button in Browser using JavaScript
I hope this will help to you.
More Related Contents:
- How to force browser to show image 3 inches wide?
- Why should y.innerHTML = x.innerHTML; be avoided?
- How can I retain the scroll position of a scrollable area when pressing back button?
- Detect if browser is running on an Android or iOS device
- Web browser: Hide mouse cursor [duplicate]
- Get one element title and add this to another div in jquery
- how do i submit message to my email by html or js?
- JS hide function error
- How to create button to check uncheckable checkbox
- JSFiddle code not working in my own page
- How to calculate the XPath position of an element using Javascript?
- Detecting if a browser is using Private Browsing mode
- How to disable scroll without hiding it?
- Uncaught Error: SECURITY_ERR: DOM Exception 18 when I try to set a cookie
- Why does Jquery only affect the first div element? [duplicate]
- Set date in input type date
- jquery select option click handler
- jQuery jump or scroll to certain position, div or target on the page from button onclick [duplicate]
- How To Show And Hide Input Fields Based On Radio Button Selection
- jQuery Validation using the class instead of the name value
- jQuery duplicate DIV into another DIV
- Modify the value of each textfield based on original value using jQuery
- How to keep the changes made to DOM by javascript/jquery on page refresh
- Onclick reload the div only
- Saving and loading an image from localStorage
- Changing cursor to waiting in javascript/jquery
- Returning value from confirmation dialog using JQuery UI dialog
- HTML5 Video autoplay with sound unmuted
- How do I dynamically adjust css stylesheet based on browser width?
- How can I calculate the difference between two times that are in 24 hour format?