views:

49

answers:

1

Thanks to everyone in advance -

I took a look at this -

http://stackoverflow.com/questions/1549831/an-observer-for-page-loads-in-a-custom-xulbrowser

I am guessing that might be a path for determining the HTTP status code, but does anyone know of an easier way? I have flipped through the contentDocument as well...no dice.

Any ideas?

Thanks,

Sam

+1  A: 

I looked for a bit and I don't think there is an easier way. The HTTP status code is an attribute of a request (and only of an HTTP request), so it appears to die with the request object (nsIHttpChannel), since nothing cares to save it.

You might be interested in this Firefox project, by the way: https://wiki.mozilla.org/Firefox/Projects/Network_Error_Pages

Nickolay
Thanks for the suggestion - here is what I ended up using to get the headers:https://developer.mozilla.org/en/nsIWebProgress
Sam Ingrassia