• I always get the same error:

    Facebook Connect error: login process failed!

    that’s it, don’t know where to start here :/

Viewing 15 replies - 1 through 15 (of 16 total)
  • Plugin Author valentinas

    (@valentinas)

    Will reply tomorrow, UTC+13. Probably something to do with cookies or something.

    Thread Starter smuda

    (@smuda)

    alright, thank you.

    Plugin Author valentinas

    (@valentinas)

    This happens when you are authorized with FB, but you are not logged in to your website. In theory that should never happen, because if you are authorized with FB, then on init WordPress will either log you in if you have an account, or if you don’t have an account then it will create one for you and then log you in. So in theory if you are authorized with FB you will always end up logged in to your site.

    Could you double check the application ID and application secret in Settings->FB Connect? Then clear cookies and try again. If that doesn’t help – let me know.

    The problem is with function that fetches data from Facebook. Some servers don’t allow to read content of the remove file by the file_get_contents().
    This means that line:
    $user = json_decode(@file_get_contents('https://graph.facebook.com/me?access_token=' . $cookie['access_token']));
    should be rewritten to the:
    $user = json_decode( get_facebook_data( $cookie['access_token'] )) ;
    + new function:

    function get_facebook_data( $access_token ) {
     // check fopen wrappers
     // check curl
     // check fsockopen
     // check sockets
    }

    Plugin Author valentinas

    (@valentinas)

    januzi_pl, thanks for info, I will try to implement this to next version.

    You’re welcome.

    You could also add simple “check server” in the admin panel. It should print info like:
    “Sorry, Your server doesn’t allow to connect with remote sources. Ask Your server administrator for further information” / “Everything looks fine. You will be able to connect with Facebook”
    + table:
    remote file | OK / FAIL
    curl | OK / FAIL
    fsockopen | OK / FAIL
    sockets | OK / FAIL

    Check out wp_remote_get

    Hi valentinas, I really like your plugin, it works like a charm, but I noticed a little thing that have to be changed as soon as possible because it may cause problems.

    When a new user is created the username is taken from the first name of who made the facebook connection.

    The problem is: what happen when another person, with the same first name, connect to the blog?

    Example: Mark Red connect his facebook to my blog and a new user, called Mark, is created. What happens when Mark Black connect to my blog?

    Sorry for my poor english, I’m italian and i did my best!

    Is it possible, at user creation, take the facebook id instead of the first name?

    Hey valentinas,

    first – thanks for the great lightweight plugin.

    A check in the backend for fopen would be nice. I searched for over 4 hours now ?? because of the

    Facebook Connect error: login process failed!

    bug.

    And another thing: Could you please add a link to the plugin site here on www.remarpro.com? When I try to find forum entries I first have to search through the plugin repository and the follow the forums link.

    Thank you!

    Cheers
    Philipp

    Plugin Author valentinas

    (@valentinas)

    Hi, philipp

    Thanks for feedback, it seems that problem with fopen is main issue with this plugin. Fix (check if fopen or any other means of getting remote url is available) will be included in next version. I can’t give an estimate due to the lack of time though. Hopefully in next few weeks.

    About the link: do you want to have a link in plugin page to forums? I’m not sure if i understand you correctly. If so, then it’s already there. While looking at the plugin description look in the right bottom corner of the screen. There is a list of recent forum topics about this plugin.

    Hey valentinas,

    about the link: i’m talking about the plugin section in the wordpress dashboard. there is no link to the plugin information on www.remarpro.com.

    cheers
    philipp

    For me after I enabled the php_openssl, the error “Facebook Connect error: login process failed!” just gone.

    Here are the steps to enable the php_openssl on wamp
    Click on the wamp icon > PHP > PHP extensions > “Click” php_openssl

    Your wamp server will be restarted automatically. If not, try to “Restart All Services”

    Thanks!

    Following JustinSainton’s advice, I modified functions.php to fix the issue of file_get_contents being disabled for remote files:

    I replaced the line:
    $user = json_decode(@file_get_contents('https://graph.facebook.com/me?access_token=' . $cookie['access_token']));

    With:

    $remote_get = wp_remote_get('https://graph.facebook.com/me?access_token=' . $cookie['access_token']);
    $body_content = $remote_get['body'];
    $user = json_decode($body_content);

    …and this fixed the issue for me.

    I’m new to www.remarpro.com and I don’t know if this is the appropriate place to post bug fixes, but I just submitted this out of impulse since I managed the fix the error on my side.

    when I used this fix, it gave me this error:

    Fatal error: Cannot use object of type WP_Error as array in \wp-content\plugins\wp-facebook-connect\functions.php on line 127

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Facebook Connect error: login process failed!’ is closed to new replies.