title: How to restrict Ctrl N combination in a browser window?
body: <p>As per my knowledge we can disable <kbd>ctrl</kbd>+<kbd>N</kbd> key for new window with the following Javascript code:</p>
  
  <pre><code>document.onkeydown = function() { 
      alert(event.keyCode) 
      if ((event.keyCode == 78) &amp;&amp; (event.ctrlKey)) { 
          alert ("No new window") 
          event.cancelBubble = true; 
          event.returnValue = false; 
          event.keyCode = false; return false; 
      } 
  }
  </code></pre>
  
  <p>In my case there are 3 frames with one of them fixed (menu bar where I can put this code), but this event is not caught if the focus is in some other frame. How can I implement this restriction globally on a browser window?</p>