I have the code below to open a new window whenever user presses F2 key.
$(document).bind('keyup', function(e){
if(e.which==113) {
window.open('newPage.htm','_blank','','false');
}
});
Now, I want to prevent user to open a new window while the previous one is still opened. How can I dot it ?