Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><code>this.channel.status</code> seems to have all the error codes. The problem is, the status is a number and they don't appear to be documented. <code>Components.results</code> contains some, but not all, of these codes and assigns them a constant. Since I couldn't find any documentation, I suppose we have to guess based on the constant, as to what went wrong. The SSL errors aren't in <code>Components.results</code> and were found through trial and error.</p> <p>Here's a function that gets some of the errors and produces a message.</p> <pre><code>// Call this from your AJAX error handler self.GetAJAXFailureCode(this.channel.status); self.GetAJAXFailureCode = function(Status){ var ERROR_CODE,ERROR_MESSAGE; // Some, but not all can be found in Components.results. // All the other codes appear to be undocumented, and have // to be discovered through trial and error (thanks Mozilla.) switch(Status){ case(2153390067): ERROR_CODE = 'sec_error_unknown_issuer'; ERROR_MESSAGE = 'The certificate was signed by an unknown Certificate Authority (add the CA to FF to fix).'; break; case(2153390069): ERROR_CODE = 'sec_error_expired_certificate'; ERROR_MESSAGE = 'The SSL certificate has expired.'; break; case(2152398879): ERROR_CODE = 'NS_ERROR_REDIRECT_LOOP'; ERROR_MESSAGE = 'You seem to be going in circles!'; break; case( 2152398864): ERROR_CODE = 'NS_ERROR_OFFLINE'; ERROR_MESSAGE = 'There is no network. There is only XUL.'; break; case( 2152398862): ERROR_CODE = 'NS_ERROR_NET_TIMEOUT'; ERROR_MESSAGE = 'The network connection timed out.'; break; case(2152398878): // This happens when the network cable is unplugged. ERROR_CODE = 'NS_ERROR_UNKNOWN_HOST'; ERROR_MESSAGE = 'Please make sure your network cable is securely fastened, and the network is up. (Unknown Host)'; break; default: ERROR_CODE = 'unknown_error'; ERROR_MESSAGE = 'An error with code '+this.channel.status+' occurred. Good luck wih that.'; } return [ERROR_CODE,ERROR_MESSAGE]; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload