Disk Depot

January 1, 2008

JavaScript Hints and Tips #1: Component returned failure code: 0×80004005 (NS_ERROR_FAILURE)

Author: technical @ 1:00 am
Filed under: programming

We’ve decided to put some of our technical tricks and tips online to serve as a resource.

If you’re getting a problem something like this in Firefox (Mozilla):-

Error: uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIXMLHttpRequest.send]“  nsresult: “0×80004005 (NS_ERROR_FAILURE)“  location: “JS frame :: file:///C:/path/path/path/path/filename.js :: someMethod :: line 888″  data: no]

when you call the send() method on an XMLHttpRequest (XMLHttpRequest.send()), it’s possibly a browser security issue. Remember that by default browser-based JavaScript scripts and apps only allow requests to the same domain that the original page came from.

In particular this may be an issue if you’re testing scripts on your local hard drive.

There are ways around this, but that’s the basic problem.

(Edited 16 Jun 2010)







Disk Depot accepts Visa, Delta, Switch, Mastercard, Solo, Maestro, PayPal and SagePay.

©2001-2012 Disk Depot - The UK's Online Blank Media and Ink Store
Blank DVDs, Blank CDs, Inkjet Carts and more - Buy online now!

Blank DVDs, Blank CDs | UK online store | Site Map | Contact Us
View Basket
Checkout
price watch
track it