Originally Posted by MrAtoBandMe
I am learning HTML and Java, and I am getting message that says, "Your session has timed out.", within my iFrame. The page that I'm trying to open in my iFrame is from a website that is not mine. The website's page that I am trying to open will automatically redirect to a page from the same website that says, "Your session has timed out."
No login is required to access the website's page that I am trying to load in my iFrame, and I can load the website fine if I paste the exact same link into my web browsers address box. This problem only occurs when I try to load the page into an iFrame.
For example, I am trying to load "www.website.com/Hello" within my iFrame, and the iFrame goes to "www.website.com/TimeOutError".
What causes this and is there a way that I can load the page within an iFrame?
A likely problem is that your host isn't allowing it, but it could also be the other website is not allowing it.
If you're simply trying to copy the contents of the website, try this PHP code to do so:
$homepage = file_get_contents('http://www.example.com/');
There are a few other options that may be available to you, but if your host does not allow you to do things like this that may be impossible as well.
It might help if you post your link so we can view the error. It's hard to diagnose something if we can't test it. For instance, you can rule out your host by checking it on this page with the iframe code you have: http://www.w3schools.com/html/tryit....e_height_width
If you get the same error, it's the other website. If you do not get an error, it's your web host.