#921 closed enhancement (fixed)
ContentPane handling of status errors
Reported by: | Owned by: | mumme | |
---|---|---|---|
Priority: | high | Milestone: | |
Component: | Widgets | Version: | 0.3 |
Keywords: | ContentPane "error handling" | Cc: | |
Blocked By: | Blocking: |
Description
When retreiving remote data into ContentPane?, if the server response with status error, for example 500 or 404, the contentPane just display "Error Loading <url> <status #> <status text>. This is done in "_downloadExternalContent" of ContentPane?.
The error is handled in such way:
self._handleDefaults.call(self, "Error loading '" + url + "' (" + e.status + " "+ e.statusText + ")" , "onDownloadError");
and then onDownloadError is a stub function.
I propose a change to handle it like this:
self.onDownloadError.call(self, url, e, "onDownloadError");
and then provide a default behavior in onDownloadError to display the text:
"Error loading '" + url + "' (" + e.status + " "+ e.statusText + ")"
Doing this will allow developer to extend and modify the behavior of ContentPane? by overriding just the onDownloadError if they choose to display the response text from the server instead of dojo's error message.
Change History (3)
comment:1 Changed 15 years ago by
Milestone: | → 0.4 |
---|---|
Owner: | changed from anonymous to mumme |
comment:2 Changed 15 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Hi !
As of r4673 there is an easier way to grab the specifics of the io.bind call.
So this makes debugging a dynamic page much easier.
example
Or look in test_RemotePane.html.
/ Fredrik