cross-domain-policy

Zend Framework 2 - AJAX Request from other server

狂风中的少年 提交于 2019-12-01 18:53:35
问题 I have 2 domains (domain A, domain B). On domain A is placed ZF2 application, and everything is ok. On domain B is placed Landing Page (small site with form to collect data). From Landing Page I want send form data to application on domain A (AJAX Request). Unfortunatelly ZF2 app on domain A didn't receive data, and didn't show results. Everything is ok when I make AJAX Request from same domain where ZF2 app is. I tried use JSONP but without success. I don't have any other clue how to force

Cross domain restrictions and subdomains

自古美人都是妖i 提交于 2019-12-01 18:10:51
Is there a cross domain policy restriction for subdomains? If I have an application on paint.xxxx.com which is manipulating images from image.xxxx.com , are there any cross domain problems? I'm asking these questions, because I'm considering putting a proxy on a subdomain. yes the cross domain restriction applies for subdomains. The solution is to put document.domain = "example.com" ; // whatever your domain name is in the top of the js file(s) for both the parent domain and the child domain Google Document.domain and cross site and there should be a better explanation but I've had the same

Cross domain restrictions and subdomains

為{幸葍}努か 提交于 2019-12-01 17:19:53
问题 Is there a cross domain policy restriction for subdomains? If I have an application on paint.xxxx.com which is manipulating images from image.xxxx.com , are there any cross domain problems? I'm asking these questions, because I'm considering putting a proxy on a subdomain. 回答1: yes the cross domain restriction applies for subdomains. The solution is to put document.domain = "example.com" ; // whatever your domain name is in the top of the js file(s) for both the parent domain and the child

Flash - HTTP requests won't work on localhost

心已入冬 提交于 2019-12-01 14:19:40
First off, I'm trying to fix something that I didn't build to begin with and the guy who's project it was assures me it was working fine when he left, although a version I haven't touched since he left seems to have the same issues. I'm also a bit new to programming in general so let me know if I've left out important information in my first post and I will try to add more info. I have a flash application hosted on-line that acts as a client for a server application written in Delphi. Most of the communication is done using sockets, which work fine. Uploading data files and downloading results

Flash - HTTP requests won't work on localhost

爷,独闯天下 提交于 2019-12-01 12:59:36
问题 First off, I'm trying to fix something that I didn't build to begin with and the guy who's project it was assures me it was working fine when he left, although a version I haven't touched since he left seems to have the same issues. I'm also a bit new to programming in general so let me know if I've left out important information in my first post and I will try to add more info. I have a flash application hosted on-line that acts as a client for a server application written in Delphi. Most of

XSLT document() usage with WebKit browsers

放肆的年华 提交于 2019-12-01 06:27:12
I'm having an issue when attempting to include and access multiple XML documents in an XSL stylesheet. I'm assigning document nodes as variables and then attempting to access them in my xsl:template, similar to this: <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output method="xml" omit-xml-declaration="yes" /> <xsl:variable name="doc1" select="document('test.xml')" /> <xsl:template match="/"> <div> <span id="id_total"> <xsl:value-of select="count($doc1//Root)"/> </span> </div> </xsl:template> </xsl:stylesheet> I get the correct count when using IE &

JavaScript access from parent domain to subdomain?

北城余情 提交于 2019-11-28 23:21:22
I've read that setting document.domain = "example.com" lets me access the parent domain from a subdomain. Will the same work the other way around? Let's say my main site is running under http://example.com . All API functions that I want to access via AJAX (GET & POST) are hosted on http:// api .example.com . Will I be able to access api.example.com from example.com ? EDIT : Looking at document.domain again, I don't think that this will solve the problem. The result from calls to api .example.com are not necessary HTML, but output from a PHP script running on the API server. It can be JSON,

Check if same origin policy applies

喜你入骨 提交于 2019-11-28 17:54:22
Is there a "safe" way to check if the same origin policy applies to an URL before actually trying to use ajax methods? Here is what I have: function testSameOrigin(url) { var loc = window.location, a = document.createElement('a'); a.href = url; return a.hostname == loc.hostname && a.port == loc.port && a.protocol == loc.protocol; } This sort of works, but it’s kind of a manual guess based on the wikipedia article . Is there a better way of pre-checking cross domain allowance? jQuery is OK to use. Interesting question! I searched around and couldn't find anything other than what you posted, but

Access-Control-Allow-Origin not working for iframe withing the same domain

[亡魂溺海] 提交于 2019-11-28 11:09:38
I'm trying to access an iframe within a subdomain and get a cross domain error. Here is the code of example .mydomain.com/iframe_test.html: <html> <head> <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script> </head> <body> <iframe src="http://example2.mydomain.com/welcome.php" width="1000" height="600"></iframe> <script> $(document).ready(function() { setTimeout(function(){ $('#innerdiv',$('iframe').contents()).hide(); },5000); }); </script> </body> </html> And here is the code of example2 .mydomain.com/welcome.php: <?php header("Access-Control-Allow-Origin: " . "

JavaScript access from parent domain to subdomain?

回眸只為那壹抹淺笑 提交于 2019-11-27 14:53:34
问题 I've read that setting document.domain = "example.com" lets me access the parent domain from a subdomain. Will the same work the other way around? Let's say my main site is running under http://example.com . All API functions that I want to access via AJAX (GET & POST) are hosted on http:// api .example.com . Will I be able to access api.example.com from example.com ? EDIT : Looking at document.domain again, I don't think that this will solve the problem. The result from calls to api .example