How do I figure out in my PHP’s code if I am in an iframe or not? I’d like the page to behave slightly differently. I was going to use HTTP_REFERER but that doesn’t seem very reliable.
Share
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.
If it’s you, who decides (or loads) whether the script is called from
IFRAMEor not, you could call it with parameter, i.e.script.php?ff=1– FromFrame and modify accordingly.