The following example listens to window.onerror event and uses an image beacon technique to send the information through the GET parameters of an URL.
var hasLoggedOnce = false;
// Some browsers (at least Firefox) don't report line and column numbers
// when event is handled through window.addE...