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

  • SEARCH
  • Home
  • 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 7796723
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T23:27:22+00:00 2026-06-01T23:27:22+00:00

Access to my developed website is done using facebook connect. Everything is OK offline,

  • 0

Access to my developed website is done using facebook connect.

Everything is OK offline, but not online. I get a navigation error (using Chrome) “This webpage has a redirect loop” :

The webpage at https://www.facebook.com/dialog/oauth?client_id=209633612480053&redirect_uri=http%3A%2F%2Fwww.bluward.com%2Faccess%2Flogin_facebook&state=299262ddf89afbf382452df89c9a2ce8&scope=email%2C+user_birthday%2C+user_about_me%2C+user_location%2C+publish_stream&fbconnect=1#= has resulted in too many redirects. Clearing your cookies for this site or allowing third-party cookies may fix the problem. If not, it is possibly a server configuration issue and not a problem with your computer.

Here is the PHP code (using CodeIgniter framework):

public function login()
{
  // Get the FB UID of the currently logged in user
  $uid = $fb->getUser();

  // If the user has already allowed the application, you'll be able to get his/her FB UID
  if($uid) {

     try {
        $profile = $fb->api(array(  
            'method'      => 'users.getinfo',  
            'uids'        => $uid,  
            'fields'      => 'uid, first_name, last_name, pic_square, pic_big, sex, birthday_date, current_location, email'
        ));

        // Only the first user.
        $profile = $profile[0];
     } catch (FacebookApiException $e) {
        return false;
     }

     // Do stuff when already logged in.

     return $profile;

  } else {

     // If not, let's redirect to the ALLOW page so we can get access
     redirect($this->getLoginUrl(array(
         'scope'           => 'email, user_birthday, user_about_me, user_location, publish_stream',
         'fbconnect'       =>  1
     )));
  }
}

And depending on the profile info, I check if the user already exists on database, then log him/her, and if not exists on database, signup him/her.

Update:

When I clear Facebook cookies, the redirect to login page is successful, and I’m able to fill email/password.

Unfortunately, when I click “log in” button, I get the same error message as I displayed above.

  • 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-01T23:27:23+00:00Added an answer on June 1, 2026 at 11:27 pm

    It looks like your using and older version? Here is how i would handle issue with php-sdk 3.1.1 “the most current version”.


    require 'src/facebook.php';
    $facebook = new Facebook(array(
      'appId'  => '135669679827333',
      'secret' => 'xxxxxxxxxxxxxxxxxxxxxxxxxxxx'
      ));
    $user = $facebook->getUser();
    if ($user) {
      try {
        // Proceed knowing you have a logged in user who's authenticated.
        $user_profile = $facebook->api('/me');
      } catch (FacebookApiException $e) {
        error_log($e);
        $user = null;
      }
    }
    if ($user) {
      $logoutUrl = $facebook->getLogoutUrl();
    } else {
    $params = array(
      scope => 'read_stream,publish_stream,publish_actions,read_friendlists',
      //redirect_uri => $url
      );
      $loginUrl = $facebook->getLoginUrl($params);
      echo '<script> top.location.href=\''.$loginUrl.'\'</script>';
    };
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Last year I developed a data access service for our project using Entity Framework
I have developed an database application with Delphi XE2 using an Access DB, now
I've developed an application at working using MySQL 5, that uses Views to access
I have developed a website using Asp.Net MVC which uses a SQL CE database
I'm trying to get the status from facebook users, who connect to my app
I've developed a Facebook page tab that doubles up as a website style app:
I'm trying to create a DLL using a Dataset.XSD file to access my website's
i have developed a php mysql website and now i want to access this
I have developed an ASP.Net 2.0 website (Using VS 2008). The website uses sqlmembershipprovider
Have any bridge libraries been developed for PHP that provide access to the jQuery

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.