I am using the following simple iFrame code to load Yahoo but it’s not loading anyway. in Chrome Inspector I see the URL status as 301 first and then cancel. Any idea why is it happening?
<iframe name="iframe1" src="http://yahoo.com"></iframe>
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You probably get an error message in the log that reads something like this:
"Refused to display document because display forbidden by X-Frame-Options."To answer your question:
Yahoo is doing this to
avoid clickjacking attacks, by ensuring that their content is not embedded into other sites.For more info read this:
https://developer.mozilla.org/en/The_X-FRAME-OPTIONS_response_header