Skip to content

Instantly share code, notes, and snippets.

@daemongh
Forked from Incognito/errorlog.sql
Created December 6, 2011 16:06
Show Gist options
  • Save daemongh/1438720 to your computer and use it in GitHub Desktop.
Save daemongh/1438720 to your computer and use it in GitHub Desktop.
Psudo-error loggging JS thinger.
CREATE TABLE errorLog (
Timestamp,
IP,
Line,
ErrorMessage,
URL,
Cookies,
UserAgent,
Plugins,
State --If we can capture the functioncall or stack or some sort of "thrown" issue.
);
window.onerror = function(error, url, line){
someAjaxyThing({
CollectBrowserDataAsObject(),
error,
url,
line
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment