It's a cross-domain request issue. You cannot do it. A work-around to request something from another domain is using something called JSONP. Read this jQuery page to get started: http://docs.jquery.com/Ajax/jQuery.getJSON#urldatacallback
On Feb 19, 6:05 am, Chris Trygstad <christrygs...@gmail.com> wrote: > According to the API documentation of jQuery, the jQuery.ajax function > is supposed to: "Load a remote page using an HTTP request." I've tried > running a function with jQuery.ajax: > var xmlDocument = 'dev.xml'; > $.ajax({ > type: "POST", > > url: "http://example.com:80/xmlservlet", > processData: false, > data: xmlDocument, > success: function(msg){ > alert( "Data Saved: "); > } > and I keep getting an error "Access to restricted URI denied" code: > "1012" when I run this with Firebug. Googling this error reveals that > it may be an issue with cross-domain AJAX requests. Further research > indicates it may be a Firefox security issue, since I am running it > from my localhost.http://jquery-howto.blogspot.com/2008/12/access-to- > restricted-uri-denied-code.html. This article says to fix it, you > should run it from an internal webserver, which is what I already have > setup from localhost with IIS, PHP, etc. > > I tried to run this in IE7 too, but didn't get the desired "Data > Saved" alert, and I don't know of a way to debug javascript in IE.