cross-domain

Cross domain iframe resizer using postMessage

若如初见. 提交于 2020-01-02 06:01:33
问题 I've read all the cross domain iframe posts here (my thanks to all of you!) and elsewhere. The postMessage script at cross-domain iframe resizer? works beautifully in Firefox 5 and up. It resizes the iframe every time a page is clicked within the iframe perfectly. But it doesn't resize at all in IE (7 8 or 9) on my computer. I checked the security settings and the one in IE for access across domains was checked to enable. Does postMessage not work in IE? - Or is there something else that

Silverlight WCF Service Cross Domain Question

删除回忆录丶 提交于 2020-01-02 04:50:28
问题 I have a silverlight app (hosted at intranet.mydomain.net) and a WCF service at (webservices.mydomain.net) Do I need a cross-site policy file? If so, what would it look like to only allow access from intranet.mydomain.net? 回答1: Yes, you will need a clientaccesspolicy.xml file in the ROOT of your service domain(webservices.mydomain.net). By default, Silverlight supports calls to Web services on the same domain or site of origin. Same domain means that calls must use the same sub domain,

JWT token for multiple websites

て烟熏妆下的殇ゞ 提交于 2020-01-02 01:00:09
问题 How can I have a single JWT token be shared among multiple websites. I assume that the first thing would be to have the same secret on all websites. If user logs in on site A and a token is generated I want to use the same token for website B on a totally diferent domain. Can it be done? 回答1: What you want can be done, but not with a single JWT token. A JWT token is intended for a certain service or application indicated by the audience ( aud ) claim. You cannot use the same token for another

AngularJS / Alfresco / CORS filter issue: No 'Access-Control-Allow-Origin' header

为君一笑 提交于 2020-01-01 19:29:30
问题 I have some problem with Alfresco (5.0.d) , my AngularJS (1.4.3) client and the CORS settings (typical cross-domain / No'Access-Control-Allow-Origin' header is present on the requested resource problem). I am calling the Alfresco REST API from an AngularJS application running on localhost: 3000 , to an Alfresco instance running on localhost: 8080 (Tomcat, no reverse-proxy in front). This XHR call works fine: http://localhost:8080/alfresco/service/slingshot/live-search-docs?t=Project&u=admin

jQuery Mobile + PhoneGap on iphone fails to loadPage

江枫思渺然 提交于 2020-01-01 17:08:48
问题 I am trying to write a simple phonegap + jqm app that gets a page from remote server. $.mobile.loadPage("http://mydomain.com/Mobile/MyPage.aspx") .done(function () { alert('done'); }) .fail(function () { alert('fail'); }); }); I set the following options: $.support.cors = true; $.mobile.allowCrossDomainPages = true; Added the following header: Access-Control-Allow-Origin:* Everything works fine when I try it in desktop browsers (ff/chrome/safari) but it doesnt work on my iphone or in the

Is it possible to make a JSONP request from HTTPS to HTTP?

杀马特。学长 韩版系。学妹 提交于 2020-01-01 10:43:28
问题 I know there is an almost duplicate question, but the answer is not satisfactory at all. I need to do geocoding using the Openstreetmap service which runs over HTTP. My site runs over HTTPS. It seems impossible to do JSONP request from https to http, browser (Chrome) complains about insecure content. Any solutions? 回答1: The reason that the browser complains about insecure content is that the content is insecure. The entire purpose with a secure page is that all of it is secure, and can be

Restangular crossdomain request. What I do wrong?

Deadly 提交于 2020-01-01 09:38:10
问题 I have domain sub.example.com with configured restangular: RestangularProvider.setDefaultHeaders({ 'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest' }); RestangularProvider.setDefaultHttpFields({ 'withCredentials': true }); Then I'm building other factory via: return Restangular.withConfig(function(RestangularProvider) { RestangularProvider.setBaseUrl('http://api.example.com'); }); And, obviously, getting error No 'Access-Control-Allow-Origin' header is present on the

Why is CloudFront varying CORS headers response based on Accept-Encoding?

独自空忆成欢 提交于 2020-01-01 07:40:09
问题 I'm trying to get CORS to work properly with Amazon S3 + CloudFront. After setting my CORS Configuration, it seems to work properly: $ curl -H "Origin: https://app.close.io" -I "https://d4389n07pf8cq.cloudfront.net/built/app.9e1f9ee9.js" -s | grep Access Access-Control-Allow-Origin: https://app.close.io Access-Control-Allow-Methods: GET, HEAD Access-Control-Max-Age: 3000 Access-Control-Allow-Credentials: true But when the resource is requested with Accept-Encoding: gzip then the CORS headers

Retrieve text file line-by-line using Jquery $.get()

假如想象 提交于 2020-01-01 05:34:11
问题 Is it possible to retrieve a txt files content line by line? Right now I'm using this code: var file = "http://plapla.com/pla.txt"; function getFile(){ $.get(file,function(txt){ save(txt.responseText); }); } the save function saves the content into a variable. And after I print it out all the content of the retrived file is in the end of each other(not line by line). 回答1: I'm not sure if you mean that when you print out the file that it gets all pushed onto one line, or if you are saying that

Backbone.js won't make cross-host requests?

杀马特。学长 韩版系。学妹 提交于 2020-01-01 03:14:13
问题 I've been playing with Backbone in my Chrome console and running into a cross-domain problem that I can't figure out. The host I'm connecting to presumably correctly implements CORS because a raw XHR request returns the expected JSON: var http = new XMLHttpRequest(); http.open('GET', 'http://example.com:3000/entities/item/15.json', true); http.onreadystatechange = function(evt) { console.log(evt); } http.send(); (logs 3 XHR progress events on the console with the correct data in the response)