0

I am trying to load the html from a url to a div container on my webpage but I am getting this error "No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access."

My website is built using only html and jquery/javascript.

$('.myContainer').load('http://s3-ap-southeast-1.amazonaws.com/myfolder/mypage.html')

Please let me know how can I resolve this error?

1

1 Answer 1

2

The page you are trying to load has this header in its response.

X-Frame-Options:SAMEORIGIN which means, other domains except for its own, can not load this URL.

X-Frame-Options is used to restrict cross-domain resource accessing.

Not the answer you're looking for? Browse other questions tagged or ask your own question.