0

I have a webpage that is accessed directly but also through a Facebook page tab. I'd like to display a Facebook logo ONLY if users are accessing the page outside of Facebook. If the user is already viewing the page through Facebook here is no need to show the logo.

How would I achieve this?

Andrew Smart
  • 381
  • 1
  • 6
  • 16

1 Answers1

1

Facebook will send POST data called 'signed_request' to your pagetabs.

https://developers.facebook.com/docs/howtos/login/signed-request/

In your php, you check to see if the page has received this request and act accordingly

if($_REQUEST['signed_request']){
    //hide logo
}else{
  //show logo
}
andymacd
  • 101
  • 4