I have a payment form in which user can enter all his card details,and when he clicks,he is taken to the banks 3D secure page. But,the problem is, the user can simply click
If user clicked back button this will redirect you to your specified page (100% Working)
window.history.pushState({page: 1}, "", ""); window.onpopstate = function(event) { if(event){ window.location.href = 'https://www.google.com/'; // Code to handle back button or prevent from navigation } }