diff --git a/src/static/js/pad_utils.js b/src/static/js/pad_utils.js index 8f7347bfd..83ee9aae8 100644 --- a/src/static/js/pad_utils.js +++ b/src/static/js/pad_utils.js @@ -502,17 +502,26 @@ var padutils = { var globalExceptionHandler = undefined; function setupGlobalExceptionHandler() { - //send javascript errors to the server if (!globalExceptionHandler) { globalExceptionHandler = function test (msg, url, linenumber) { - var errObj = {errorInfo: JSON.stringify({msg: msg, url: url, linenumber: linenumber, userAgent: navigator.userAgent})}; - var loc = document.location; - var url = loc.protocol + "//" + loc.hostname + ":" + loc.port + "/" + loc.pathname.substr(1, loc.pathname.indexOf("/p/")) + "jserror"; + var errorId = randomString(20); + if ($("#editorloadingbox").attr("display") != "none"){ + //show javascript errors to the user + $("#editorloadingbox").css("padding", "10px"); + $("#editorloadingbox").css("padding-top", "45px"); + $("#editorloadingbox").html("