Advertisement:

Author Topic: Facebook Connect Not Working  (Read 9798 times)

tascam424

  • Newbie
  • *
  • Posts: 47
Facebook Connect Not Working
« on: September 01, 2013, 04:26:25 pm »
Hi all i successfully integrated the Facebook connect plugin back in May and it was working perfectly. However i have just noticed in the last few days that it has stopped working. Basically when I hit the Login with Facebook button, it creates a long URL in the address bar and refreshes the page, but it neither signs in or creates an account.

Any ideas ?

Any help will be greatly appreciated.

Thanks.

OSClass 3.1.2
Bender Theme.

garciademarina

  • Administrator
  • Hero Member
  • *****
  • Posts: 974
Re: Facebook Connect Not Working
« Reply #1 on: September 02, 2013, 11:28:25 am »
Hi, tascam424,

I just tried osclass 3.2.1 with latest version of fb plugin and wll work fine,

Do you have the latest version of FB plugin ? you can install it from oc-admin -> market plugins.

Regards

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #2 on: October 17, 2013, 12:58:00 am »
Hi all

I just install the facebook plugin and created the FB app then I config the plugin and added the api and sercert key

I have the same issues as inthe post below
I am using the bender theme with osclass 3.2

I search all facebook posts  in the forum and tried all soultions posted, still not working!
Did i miss something in the fix for this issues?


Kindest regards,
AVBestDeals


Hi all i successfully integrated the Facebook connect plugin back in May and it was working perfectly. However i have just noticed in the last few days that it has stopped working. Basically when I hit the Login with Facebook button, it creates a long URL in the address bar and refreshes the page, but it neither signs in or creates an account.

Any ideas ?

Any help will be greatly appreciated.

Thanks.

OSClass 3.1.2
Bender Theme.

strata

  • Sr. Member
  • ****
  • Posts: 411
  • Always good, always...
Re: Facebook Connect Not Working
« Reply #3 on: October 17, 2013, 04:09:00 am »
I have osclass latest version with facebook login and working great, please check where you put <?php fbc_login;?>

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #4 on: October 17, 2013, 10:02:12 am »
I download the fb plugin from the market just today it reads ver. 1.3.1
using osclass 3.2 and standard bender and bender black and tried to install in the header and in the login form page

new users gets created in the db, but there is no username input saved?
and it give the error that the user is not validated

Please advise

AVBestDeals

Hi, tascam424,

I just tried osclass 3.2.1 with latest version of fb plugin and wll work fine,

Do you have the latest version of FB plugin ? you can install it from oc-admin -> market plugins.

Regards

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #5 on: October 17, 2013, 10:42:26 am »
ok here is what i see so far

When i click on the fb connect link/button it does add the user to the db, but the user in not activated,
I manually activate the user and the the user can login, sot he plugin is not settup/update the users status and not adding the username to the db when the user is created using the fb connect

What can be the issues of not updating the user active status so they can then login and not get the user is not activated

AVBestDeals

garciademarina

  • Administrator
  • Hero Member
  • *****
  • Posts: 974
Re: Facebook Connect Not Working
« Reply #6 on: October 17, 2013, 06:46:18 pm »
Hi AVBestDeals,

I test it too and if have this settings:

- Users enabled
- Anyone can register
- Users need to validate their account

I can register an account with fb login, this user is active by default, If I register a new user through default registration form this user will need to validate his account.

Facebook logins it's not  validation needed. 

Quote
new users gets created in the db, but there is no username input saved?

Right now user identifier is used as username, you need to think that username must be unique and you still can edit it via my account link under the user profile page.

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #7 on: October 17, 2013, 07:00:43 pm »
Hi Garciademarina

Yes i have them all on

Settings:
Users enabled (checked)
Anyone can register (checked)
Users need to validate their account (checked)
Admin notifications When a new user is registered (checked)
                       

This is for new FB connect/login users not for the direct signup form
Yes i understand the new FB user will be able to edit the username,
but only if it works and the user account is validated when fackbook connect is used,
right now the new user is saved, but not able to login,
it then errors with the "This user is not validated" and the only way i found it to work is to manually validate the new user created by fb plugin in my testing of the FB plugin

Does the new user created by the fb plugin be auto valifated to then be able to login?

Please do reply back, i do not wish for this issues to be dropped , as i really would like to use the fb plugin in my new OSClass website

Thanks in advance for all you help & support

AVBestDeals


 

Hi AVBestDeals,

I test it too and if have this settings:

- Users enabled
- Anyone can register
- Users need to validate their account

I can register an account with fb login, this user is active by default, If I register a new user through default registration form this user will need to validate his account.

Facebook logins it's not  validation needed. 

Quote
new users gets created in the db, but there is no username input saved?

Right now user identifier is used as username, you need to think that username must be unique and you still can edit it via my account link under the user profile page.
« Last Edit: October 17, 2013, 07:02:18 pm by AVBestDeals »

garciademarina

  • Administrator
  • Hero Member
  • *****
  • Posts: 974
Re: Facebook Connect Not Working
« Reply #8 on: October 17, 2013, 07:11:03 pm »
Quote
Does the new user created by the fb plugin be auto valifated to then be able to login?

In my case with latest versions of osclass and fb plugin, users created by the fb plugin are validated.

Try it on a new installation (without any modifications with only fb plugin) to be sure. (thats what I do)

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #9 on: October 17, 2013, 07:17:04 pm »
Hi Garciademarina

thanks for the quick reply!

I did a small test yesterday and install the bender black theme
without any modifications and added the fb code to the header and to the login page
it still did not work for me, same the error come us as "This user is not validated"

not sure if you could privately contact me to do a show and tell screen sharing of this issue

Kindest regards

AVBestDeals
 

AVBestDeals

  • Full Member
  • ***
  • Posts: 121
Re: Facebook Connect Not Working
« Reply #10 on: October 17, 2013, 11:49:34 pm »
Hello osclass forum staff


I see in the code that it should make the b_active = 1

 // activate user in case is not activated
                    $manager->update( array('b_active' => '1')
                                     ,array('pk_i_id' => $oscUser['pk_i_id']) );

The user is being created, but the b_active is 0 in the db
and the error is give me = The user has not been validated yet

from this code below:

if( ( $rs !== false ) && ( $rs->numRows() === 1 ) ) {
                    $fbUser = $rs->row();
                    if( count($fbUser) > 0 ) {
                        require_once osc_lib_path() . 'osclass/UserActions.php';
                        $uActions = new UserActions( false );
                        $logged   = $uActions->bootstrap_login( $fbUser['fk_i_user_id'] );

                        switch( $logged ) {
                            case 0: osc_add_flash_error_message( __( 'The username doesn\'t exist', 'facebook' ) );
                            break;
                            case 1: osc_add_flash_error_message( __( 'The user has not been validated yet', 'facebook' ) );
                            break;
                            case 2: osc_add_flash_error_message( __( 'The user has been suspended', 'facebook' ) );
                            break;
                        }

so the user is not being able to login or access the site

Please review the live site to see
http://www.avbestdeals.com


AVBestDeals

garciademarina

  • Administrator
  • Hero Member
  • *****
  • Posts: 974
Re: Facebook Connect Not Working
« Reply #11 on: October 18, 2013, 12:58:40 pm »
Hi AVBestDeals,

If you can see this code in your plugin files ....

Can you turn on osclass debug ? follow this instructions:

- http://doc.osclass.org/Debug_PHP_errors

- http://doc.osclass.org/Debug_SQL_queries

Once debug is on, try again to register new user via fb plugin and send us back your logs

MezaTech

  • Newbie
  • *
  • Posts: 2
Re: Facebook Connect Not Working
« Reply #12 on: November 27, 2013, 06:14:29 pm »
Hello All
i am new user with you , but going to be big fan of os script
i face the same problem and found the solution

easily  go to file plugins/facebook/src/base_facebook.php

edit line 134 whick contain

public static $CURL_OPTS = array(
        CURLOPT_CONNECTTIMEOUT => 10,
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_TIMEOUT => 60,
        CURLOPT_USERAGENT => 'facebook-php-3.2'
    );


and replace this function with

public static $CURL_OPTS = array(
        CURLOPT_CONNECTTIMEOUT => 10,
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_TIMEOUT => 60,
        CURLOPT_USERAGENT => 'facebook-php-3.2',
        CURLOPT_SSL_VERIFYPEER => false,
        CURLOPT_SSL_VERIFYHOST => 2
    );

Hope that is useful for you
Regards
Amr

nijamutheen

  • Newbie
  • *
  • Posts: 21
Re: Facebook Connect Not Working
« Reply #13 on: June 09, 2017, 02:07:40 pm »
i also  successfully integrated the Facebook connect plugin,Basically when I hit the Login with Facebook button, it creates a long URL in the address bar and refreshes the page, but it neither signs in or creates an account.  Any ideas ?