Chris G.
Chris G.

Reputation: 25964

How to set X-FRAME-OPTIONS to "ALLOW-FROM"

How do you set/allow cross origin in AngularDart.

I have tried just to set it in the index.html, and looked for it i code?

Like:

.headers["X-FRAME-OPTIONS"] = "ALLOW-FROM http://http://x.x.x.x/mypath"

I am forwarding from a domain: subdomain.domain.com Thats is why I think I need to ALLOW-FROM x.x.x.x/mypath. It works without <subdomain>.domain.com but I need the subdomain.

I get:

Refused to display 'http://x.x.x.x/mypath' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

Upvotes: 0

Views: 3944

Answers (1)

G&#252;nter Z&#246;chbauer
G&#252;nter Z&#246;chbauer

Reputation: 657248

https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options

The X-Frame-Options HTTP response header

which means this is set on the server on responses, not by the client. There is no point setting that in Angular.

Upvotes: 1

Related Questions