title: Possible to capture all events in a web browser?
body: <p>I am working on a pet project and am at the research stage.</p>
  <h2>Quick summary</h2>
  <p>I am trying to intercept all form submits, onclick, and every single keydown.  My library of choice is either jquery, or jquery + prototypejs.  I figure I can batch up the events into a queue/stack and send it back to the server in time interval batches to keep performance relatively stable.</p>
  <h3>Concerns</h3>
  <p>Form submits and change's would be relatively simple.. Something like</p>
  <pre><code>$(&quot;form :inputs&quot;).bind(&quot;change&quot;, function() { ... record event... }); 
  </code></pre>
  <p>But how to ensure I get precedence over the applications handlers as I have a habit of putting return false on a lot of my form handlers when there is a validation issue.  As I understand it, that effectively stops the event in its tracks.</p>
  <h2>My project</h2>
  <p>For my smaller remote clients I will put their products onto a VPS or run it in my home data center.  Currently I use a basic authentication system, given a username/password they see the website and then hopefully send me somewhat sane notes on what is broken or should be tweaked.</p>
  <p>As a better solution, I've written a simple proxy web server that does the above but allows me to have one DNS entry and then depending on credentials it makes an internal request relaying headers and re-writing URLS as needed.  Every single html/text or application/* request is compressed and shoved into a sqlite table so I can partially replay what they've done.  Now I am shifting to the frontend and would like to capture clicks, keydown's, and submits on everything on the page.</p>