title: jquery intercepting paste event
body: <p>I've binded a paste event from an input:</p>
  
  <pre><code>$(document).ready(function(){
        $('.myInput').bind("paste",function(e) {
            console.log(e);
        });
  });​
  </code></pre>
  
  <p>Everytime I hit CTRL-V it returns the <code>e</code> event object.</p>
  
  <p>I want to get the data the user is about to paste in the input. </p>
  
  <p>By inspecting the event object I found the value in several places such as:</p>
  
  <ul>
  <li><code>e.srcElement.value</code></li>
  <li><code>e.target.value</code></li>
  </ul>
  
  <p>But those ones return the value in the input after the paste happened. So If I paste some text after I entered another string, I'll get both strings concatenated.</p>
  
  <p>I've search trought the internet and found nothing but ugly flash solutions.</p>
  
  <p>Is there a clean way to do this in jquery?</p>
  
  <p>I thought about getting the whole text with <code>e.srcElement.value</code> after getting the input value <code>before</code> the paste, then compare both string and eliminate the first part, returning by consecuence the value of the clipboard.</p>