Reputation: 4000
I would like to strictly close Browser window with "OK" button instead of "YES/NO"
<body onload="javascript:window.opener='x';window.close();">
Upvotes: 1
Views: 860
Reputation: 1664
Try this:
<script type="text/javascript">
function closeWithOKButton(){
alert('Some info');
window.open('','_self').close();
}
</script>
Upvotes: 1