title: Disable Ctrl+A,Ctrl+C key functions to HTMl page
body: <p>How do I disable <kbd>Ctrl</kbd>+<kbd>A</kbd> and <kbd>ctrl</kbd>+<kbd>C</kbd> keys to my whole page? I want to disable Copy, paste functionality from the keyboard. I found a few links which disable only one textbox. but I want to disable the <code>ctrl</code> functionality to the whole HTML page. </p>
  
  <p>I pasted the below code in  tag and added the <code>disablePage</code> in body <code>onload</code>  function.</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;html lang="en"&gt;
  &lt;head&gt;
      &lt;title&gt;html2canvas example&lt;/title&gt;
   &lt;script type="text/javascript" src="img/html2canvas.js"&gt;&lt;/script&gt;
  &lt;script language=JavaScript&gt;
  function ieClicked() {
      if (document.all) {
          return false;
      }
  }
  function firefoxClicked(e) {
      if(document.layers||(document.getElementById&amp;&amp;!document.all)) {
          if (e.which==2||e.which==3) {
              return false;
          }
      }
  }
  if (document.layers){
      document.captureEvents(Event.MOUSEDOWN);
      document.onmousedown=firefoxClicked;
  }else{
      document.onmouseup=firefoxClicked;
      document.oncontextmenu=ieClicked;
  }
  document.oncontextmenu=new Function("return false")
  function disableselect(e){
      return false
      }
      function reEnable(){
      return true
      }
      document.onselectstart=new Function ("return false")
      if (window.sidebar){
      document.onmousedown=disableselect
      document.onclick=reEnable
      }
  &lt;/script&gt;
      &lt;style&gt;
      canvas{border:1px solid #222}
      &lt;/style&gt;     
  &lt;/head&gt;
  &lt;body&gt;
     &lt;a class="upload"  &gt;Upload to Imgur&lt;/a&gt;  
     &lt;a href="#" download="canvasexport.pdf" onclick="window.print()" &gt;&lt;img src="images/print-icon.png" alt="Print" width="16" height="16" &gt;&lt;/a&gt;
  
     &lt;a href="#" id="download" download="diversio.pdf" onclick="printImg();"&gt; 
     &lt;img src="images/print-icon.png" alt="Print" width="16" height="16" &gt;
     &lt;/a&gt; 
  
      &lt;h2&gt;this is &lt;b&gt;bold&lt;/b&gt; &lt;span style="color:red"&gt;red&lt;/span&gt;&lt;/h2&gt;   
      &lt;p&gt; Feedback form with screenshot This script allows you to create feedback forms which include a screenshot, 
      created on the clients browser, along with the form. 
      The screenshot is based on the DOM and as such may not be 100% accurate to the real 
      representation as it does not make an actual screenshot, but builds the screenshot based on the 
      information available on the page. How does it work? The script is based on the html2canvas library,
       which renders the current page as a canvas image, by reading the DOM and the different styles applied 
       to the elements. This script adds the options for the user to draw elements on top of that image, 
       such as mark points of interest on the image along with the feedback they send.
        It does not require any rendering from the server, as the whole image is created on the clients browser.
         No plugins, no flash, no interaction needed from the server, just pure JavaScript! Browser compatibility Firefox 3.5+ Newer versions of Google Chrome, Safari &amp; Opera IE9
      &lt;/p&gt;
  
  
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>