Merge pull request #1559 from ether/url-report
post url with pad error msg resolves #1558
This commit is contained in:
commit
80be45ad71
|
@ -520,11 +520,11 @@ function setupGlobalExceptionHandler() {
|
||||||
$("#editorloadingbox").css("padding", "10px");
|
$("#editorloadingbox").css("padding", "10px");
|
||||||
$("#editorloadingbox").css("padding-top", "45px");
|
$("#editorloadingbox").css("padding-top", "45px");
|
||||||
$("#editorloadingbox").html("<div style='text-align:left;color:red;font-size:16px;'><b>An error occured</b><br>The error was reported with the following id: '" + errorId + "'<br><br><span style='color:black;font-weight:bold;font-size:16px'>Please send this error message to us: </span><div style='color:black;font-size:14px'>'"
|
$("#editorloadingbox").html("<div style='text-align:left;color:red;font-size:16px;'><b>An error occured</b><br>The error was reported with the following id: '" + errorId + "'<br><br><span style='color:black;font-weight:bold;font-size:16px'>Please send this error message to us: </span><div style='color:black;font-size:14px'>'"
|
||||||
+ "ErrorId: " + errorId + "<br>UserAgent: " + navigator.userAgent + "<br>" + msg + " in " + url + " at line " + linenumber + "'</div></div>");
|
+ "ErrorId: " + errorId + "<br>URL: " + window.location.href + "<br>UserAgent: " + navigator.userAgent + "<br>" + msg + " in " + url + " at line " + linenumber + "'</div></div>");
|
||||||
}
|
}
|
||||||
|
|
||||||
//send javascript errors to the server
|
//send javascript errors to the server
|
||||||
var errObj = {errorInfo: JSON.stringify({errorId: errorId, msg: msg, url: url, linenumber: linenumber, userAgent: navigator.userAgent})};
|
var errObj = {errorInfo: JSON.stringify({errorId: errorId, msg: msg, url: window.location.href, linenumber: linenumber, userAgent: navigator.userAgent})};
|
||||||
var loc = document.location;
|
var loc = document.location;
|
||||||
var url = loc.protocol + "//" + loc.hostname + ":" + loc.port + "/" + loc.pathname.substr(1, loc.pathname.indexOf("/p/")) + "jserror";
|
var url = loc.protocol + "//" + loc.hostname + ":" + loc.port + "/" + loc.pathname.substr(1, loc.pathname.indexOf("/p/")) + "jserror";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue