MagSafe
2008-07-13, 17:19
Hi,
I'm trying to get my web app to handle errors "gracefully" by fading the interface and outputting a custom pop-up window telling the user something unexpected happened.
This works kind of when simple things don't work properly, but as soon a variable isn't defined, or a variable exists but isn't what is expected, all hell breaks loose!
I looked at the onerror command for a while, but then quickly realised this isn't very well supported, and is also quite an old standard. I then moved onto using try/catch methods which is what I'm on now. This works pretty well, but I'm still thinking there might be an even better way of doing it.
I thought I'd ask on here to see if anyone that develop's app's (on the web or otherwise) could share their experience with error handling?
Thanks :)
Steve.
I'm trying to get my web app to handle errors "gracefully" by fading the interface and outputting a custom pop-up window telling the user something unexpected happened.
This works kind of when simple things don't work properly, but as soon a variable isn't defined, or a variable exists but isn't what is expected, all hell breaks loose!
I looked at the onerror command for a while, but then quickly realised this isn't very well supported, and is also quite an old standard. I then moved onto using try/catch methods which is what I'm on now. This works pretty well, but I'm still thinking there might be an even better way of doing it.
I thought I'd ask on here to see if anyone that develop's app's (on the web or otherwise) could share their experience with error handling?
Thanks :)
Steve.