cross-domain

Can I tell if a frame access will be cross-domain before performing it?

I am trying to find the DOM iframe or frame element for each of the frames in a window's frames collection. The fastest way to do this, I think, is to access the frame's frameElement property. This property is only available for a same-domain access, and returns undefined and prints an error message to the log in the cross-domain case. ...

Cross-domain Requests with jQuery doesn't work in Facebook App

I want to make a HTTP request in order to receive the contents of the home page of the logged-in user of facebook.com inside my Facebook App. The app loads inside an iframe. I am using the Cross-domain Ajax mod for jQuery made by James Padolsey: http://james.padolsey.com/javascript/cross-domain-requests-with-jquery/ . This mod works fine...

Cant access values inside my iFrame it gives me permission denied

Hello I cant access values inside my iFrame it gives me permission denied. I have access on both pages (parent and child). I added the following javascript line on both pages: document.domain = "sub.domain.com"; but firebug gives me : Illegal document.domain value and when i try to access element inside the iFrame it prompts : Permi...

lightbox like script cross-domain iframe in firefox

I'm looking for a lightbox-like script that can open a cross-domain iframe in Firefox. I tried several scripts and Firebug says that it's not possible to get Window.frmResource property. Thanks in advance ...

How to use js to access data in another domain

Hi I'm trying to access data locating on following server: http://ceda.ac.uk/dap/coads.nc.html the file name is coads.nc. Instead of accessing the file, I want to use js to get the page of coads.nc as shown above. There is one example on the website, they have done this by putting both the data and the webpage on the same server, how c...

Permission error when using Ajax on a protocol other than http

Hello, We are using a custom protocol handler to connect to an embedded device across firewalls, NAT etc. The solution is called Nabto. This works great - a plug-in on the user's computer handles requests to all nabto:// URIs and serves HTML pages with information about the current connections etc. Now, we would like to access Nabto fu...

Can an AJAX request be made to a file residing on the server a Javascript file is hosted on when included on a remote site?

Ok so my question title may have been a little confusing. Here's my example: www.WebsiteA.com is hosting MyFile.js at http://www.WebsiteA.com/MyFile.js. This file makes an AJAX request for http://www.WebsiteA.com/location/file When this Javascript file is included on WebsiteB through the script tag, will the Javascript run into cross-...

Making JavaScript call across domains

Here's the goal: Hand off a script tag that references a JavaScript file on a remote server. That JavaScript file should return HTML that will then be displayed on the calling HTML page. I've attempted to approach this in two ways: First, I attempted to use XMLHttpRequest in JavaScript to call this remote server. In IE, it would wor...

Wiring up JSONP using JQuery and WCF

I'm trying to get a cross domain call to work using JSONP within JQuery. In IE, the alert method never executed. In FF/Safari/Chrome, it's always null. I looked at Fiddler and the result from the WCF method is as I'm expecting, which is: method({"Name":"blah1","Data":"blah2"}); Here's my JavaScript: $.getJSON("http://localhost:560...

using postmessage to refresh iframe's parent document

I have a greasemonkey script that opens an iframe containing a form from a different sub-domain as the parent page. I would like to refresh the parent page when the iframe refreshes after the form submission I am at the point where I can execute a function when the iframe refreshes, but I cannot get that function to affect the parent d...

need tips for creating a javascript widget

Hi, I am building a web application and I need to create a feedback form widget so the users can put it in their websites and all the submitted data will be saved in my web application. I also need to have authentication in the widget before the user can submit the information (using my application login form or a facebook account for ex...

How to disable Cross Domain Restriction

I am providing web service which return data as JSON object. The problem is with Ajax, Ajax can't call cross domain url. Is it possible to disable it? ...

cakephp .htacccess with multiple domains

I have my cakephp .htaccess files set up as in the cookbook and everything is working fine. My web site currently has multiple domains, all of which point to the same site (e.g. www.site.com, www.site.co.uk). I'd like to set up a rule so that requests to www.site.co.uk/page are permanently redirected to www.site.com/page, etc. I'm havi...

Custom Domain Service Fails but Authentication Works (Silverlight Biz App Template)

I'm hosting a Silverlight Business Application Template derived application on an IIS Server. I'm using the built-in Forms Authentication which is working perfectly. Unfortunately, I've added an additional service which has peculiar behavior. If I remote into the server and use the site everything works as expected. If I connect to the ...

XMLHttpRequest cannot load an URL with jQuery

Hi everybody, I'm trying to get some json data from a "remote" website. I run my web service on the 99000 port then, I launch my website on the 99001 port (http://localhost:99001/index.html). I get the following message: XMLHttpRequest cannot load http://localhost:99000/Services.svc/ReturnPersons. Origin http://localhost:99001 is ...

How to make a cross domain AJAX POST call from a Sharepoint Webpart?

I need to call a (HTTP) REST API as as POST call - basically, it allows me to post a message to a forum/community. Since, there is currently no way of authenticating over the API, I need to depend on browser cookies. ie, have the user logged in to the community and then use the API calls. This means, server proxies are ruled out. And b...

extjs: load tree via json returned from Ext.data.JsonStore

Hi All i have a extjs TreePanel that i need to load using json data (cross-domain call) returned from my Ext.data.JsonStore call. That works perfectly. I just cant find a way to use the returned jsonStore to load the treepanel. Any ideas? I am real desperado. Thanks everyone! code snippet: var store = new Ext.data.JsonStore({ roo...

UploadStringAsync not working

Hello, I'm trying to send a POST request to a PHP script ("http://mywebsite/index/test/" in this case) once a button is clicked. I am using the WebClient's method UploadStringAsync for that but it doesn't seem to work: using System; using System.Collections.Generic; using System.Linq; using System.Net; using System.Windows; using System...

Load local JSON files via file:// triggers cross-domain null origin violation, solution? (jQuery)

Hi all, I have a webpage I'd like to use locally, without a web server, by simply opening the local HTML file in my browser. This webpage in question loads data via jQuery's getJson() method, as in: $.getJSON("mydata.json", function(j) { ... The JSON files are also local, and are stored in the same directory as the webpage. When I a...

jQuery (cross domain) .getJSON, store response in re-usable variable

I want to get the IP from the current user and send it along with an AJAX POST to a PHP file. Which means I need to re-use the variable I get in the response from the IP .getJSON request. Script 1: I found this handy snippet on snipt: $.getJSON("http://jsonip.appspot.com?callback=?",function(data){ alert( "Your ip: " + data.ip); })...