Jump to content

Detecting if Page Is Inside an Iframe


thewird

Recommended Posts

No. php runs on the server. iframes run on the client. Javascript can do something for you - maybe. Google from javascript frame detection and/or frame busting.
Link to post
Share on other sites
[!--quoteo(post=352689:date=Mar 7 2006, 07:13 PM:name=thewird)--][div class=\'quotetop\']QUOTE(thewird @ Mar 7 2006, 07:13 PM) [snapback]352689[/snapback][/div][div class=\'quotemain\'][!--quotec--]What if I'm the one creating the iframe? Is there anything I can do to give some sort of signal?[/quote]
Well, that's a different question entirely. If you created the iframe you already know that you've placed a page in it, don't you? 'Some sort of signal' - to do what? how? when? why? Add some code to it ....
[code]<?php
echo "Hello world. This is in an iframe";
$whereami = "framed";
?>[/code]
If you want to explain what you're trying to do, then maybe someone can come up with a solution for you. Otherwise, it's just a guess at what might work.
Link to post
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.