Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Log javascript errors from another subdomain

window.onerror in Firefox and Chrome seems to discard the real error message/location and always pass "Script error.", "", 0 when the offending script is on a different domain than the page itself. I have a site with separate www and static subdomains for pages and css/js, which renders error logging rather useless. Is there any way to enable the proper logging of such errors?

like image 428
Tgr Avatar asked Sep 02 '26 07:09

Tgr


1 Answers

It doesn't sound like there's a workaround for this at the moment (I asked in the Mozilla IRC channel).

I've filed these bug reports to track this issue. Please chime in if you have opinions on what the best solution to this would be:

https://bugzilla.mozilla.org/show_bug.cgi?id=696301

https://bugs.webkit.org/show_bug.cgi?id=70574

like image 141
broofa Avatar answered Sep 03 '26 21:09

broofa