Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8920641
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T06:19:32+00:00 2026-06-15T06:19:32+00:00

Is it possible to check if an app is loaded inside the canvas or

  • 0

Is it possible to check if an app is loaded inside the canvas or not?
I only want people to use my app inside the Facebook canvas, and not outside.

I’m using the Facebook Javascript SDK, while reading about the signed_request (http://developers.facebook.com/docs/howtos/login/signed-request/), I saw that a signed_request is POSTed when the app is loaded inside the canvas.

However I can’t find any way to check this in Javascript, when using FB.getLoginStatus, there is always a signed_request, no matter if it’s inside the canvas or not.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T06:19:34+00:00Added an answer on June 15, 2026 at 6:19 am

    It looks like you have found the solution: You have to use PHP (or whichever server-side language you are using) to determine whether the page is being viewed through Facebook.

    For those who have not figured it out, you use PHP to determine whether the variable signed_request was posted to the page. If it was not, then you can redirect to the appropriate Facebook page, or take other action as desired.

    <?php
    //if signed_request was not posted...
        if ( !isset ($_POST['signed_request'] ) ) 
            {
            $redirect = 'http://apps.facebook.com/exampleapp'; //the URL of your Facebook canvas app
            header('Location:'.$redirect); //redirect the browser there
            }
    ?>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

is it possible to check when i recycled the app pool last time, i
Possible Duplicate: check whether internet connection is available with C# I just want to
Is it possible to check the gem version of the currently loaded gem in
Possible Duplicate: How to check if internet connection is present in java? I want
I know it's possible to get the images in the Photos.app by using ALAssetsLibrary
Is it possible to check in code if the app was started or published
Is it possible to check on startup of an Android app whether the user
Possible Duplicate: Check orientation on Android phone I am writing an app that requires
Is this possible to check in assembly what client (winforms app or asp.net page)
I'm making an app for my school which people can check with if they've

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.