Someone asked me to add a facebook connect login to their drupal site, unfortunately I've never used drupal before and I'm having issues.
I've been following the instructions in the readme for setting up this module, I was doing good until I got to:
"5. Enter the Connect URL on Connect settings tab (e.g. copy value from admin/settings/fbconnect field “Connect urlâ€)."
There doesn't seem to be a connect settings tab in the apps anymore so I just guessed it was the "Site URL" in the "Web Site" tab.
Then I got step 7:
"7. Configure the module through the Fbconnect module (admin/settings/fbconnect) using the information provided by Facebook
(API key, Secret API key). If you are unsure what to do on tab App Settings just press the Save configuration button."
And I copied the app id, and app secret, but when I click the app settings tab in drupal it tells me "Ensure that you entered valid api keys." I know they are correct. I found an issue on here where a guy re-installed his module and that worked for him, but it did not work for me.
So yeah, any tips on how to get this working? I am really confused, it took me forever just to find the page.tpl.php for step 8 because I didn't know drupal kept themes in two places, so it's entirely possible it's something really simple.
Thanks for any help anyone is able to provide.
Comments
Comment #1
sukr_s commentednote you should use the FB AppId and not API key. use the appid and secret key.
Comment #2
nkalush commentedThanks for the reply,
I have been using the appid, there's a message below the input box saying which one to use even though the readme is wrong.
Comment #3
theatereleven commentedI'd love to know how you even get this to print on the Drupal site. I've got my App ID and all that done, but cannot print it anywhere in my theme.
Comment #4
bananazz commentedThis is a royal pain, i have installed everything the way it should and keep getting the "Ensure that you entered valid api keys." error.
Comment #5
sukr_s commentedhave you downloaded the fb php sdk. you need to download it from http://github.com/facebook/php-sdk/? see the readme.txt
Comment #6
nkalush commentedThanks sukr_s, that is probably my main problem, I've installed it to the module directory like it asks to do in the readme, and when I go to /modules/fbconnect/facebook-php-sdk/src/facebook.php file it shows a blank page as opposed to a 404, so I'm guessing it's accessible. However when I check /admin/reports/status it's telling me it can't find the facebook php sdk, do I have to tell the plugin that it is in the module directory somehow?
Comment #7
nkalush commented@bananazz
Checking /admin/reports/status told me what I was doing wrong, maybe that would help you too.
Comment #8
sukr_s commentedrunning out of ideas, did you check the permissions on the fb sdk folder & files (on linux/ubuntu). they need to have the same permissions as the fbconnect module.
Comment #9
ducdebreme commentedI solved my problem. This is how:
First I had the SDK at this path
sites/all/fbconnect/facebook-php-sdkbut my site got a white screen and an error in the Apache error-log:
PHP Fatal error: Call to undefined method Facebook::getSessionThen I found a hint to move the SDK to
sites/all/fbconnect/php-sdkBut now I in fbconnect's admin section got the error message "Ensure that you entered valid api keys"
and in Drupal's status report I found "Facebook PHP library not found"
I could solve the problem by setting a symbolic link
ln -s php-sdk facebook-php-sdkNow I have this dirs with SDK
sites/all/fbconnect/php-sdksites/all/fbconnect/facebook-php-sdkComment #10
ducdebreme commentedSorry, I was too fast.
It's not working
New solution I really had to use SDK version 2.1.1 from http://github.com/facebook/php-sdk/tarball/v2.1.1 - this worked immediately!
Comment #11
rehanz commenteddid anyone manage to het this to actually work ??, ive been trying for a few days and nothings happening for me.
Comment #12
Anonymous (not verified) commentedAbsolutely fantastic! This worked for me! (response #10)
Thanks
Comment #13
hacmx commentedPlease update module to support last facebook sdk version...
thanks!
Comment #14
druper commentedThat (#10) was so totally it, ducdebreme. Thanks for digging that out. I was getting the blank page syndrome too but it was also bringing the whole site down!
Comment #15
salientknight commentedWorked on one site... with the code in libraries/facebook-php-sdk/facebook.php
Does not seem to work in any way on another site... copied the install code from the working site.
Comment #16
salientknight commentedWhat path did you wind up with?
Comment #17
mrjeeves commented+1 for comment #10, that did it for me too
Comment #18
natanaugusto commentedI just commented the line relative to "$libraries['facebook-php-sdk']['version arguments']['lines'] = 10" on fbconnect_libraries_info.
The argument 'lines' limits the number of lines to search for the pattern. The default value is 20.
Comment #19
roblogHurray .. I finally got this to install using the latest dev version. The trick was to get the right sdk .. as specified in
the fbconnect.module file under the fbconnect_libraries_info() function:
https://github.com/facebook/facebook-php-sdk-v4/archive/4.0-dev.zip
Phew!
Comment #20
gobinathmClosing the issue. It was inactive for a long time & it's related to a Drupal Version which is not supported anymore