Active
Project:
Drupal for Facebook
Version:
6.x-3.2-rc3
Component:
Facebook Connect
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
19 Feb 2012 at 22:11 UTC
Updated:
14 Mar 2012 at 20:44 UTC
Hello. Can somebody please explain the difference between these two? What is Your choice? What is better to use?
Are we supposed to pick only one or it can work when both are selected?
I had some issues for both settings, so i need your opinion.
Thanks.
Comments
Comment #1
miccelito commented'Use FB Cookie' would be the best choice for DFF 6.x-3.2-rc3.
I use DFF 6.x-3.2-rc3 and the latest version of Facebook PHP SDK (released 2012-01-25) at the moment and these are my settings in DFF:
[x] Use FB Cookie
[ ] Store tokens in session
[x] Use Oauth when initializing javascript.
[x] Get login status when initializing javascript.
[ ] Alternative verify login status when initializing javascript.
[x] Use tokens in session to initialize javascript
[x] Append hash on javascript page reload
But besides those settings there are also few other things to do/set to get the DFF run i.e:
Be sure you don't have other modules (especially those using redirects at user login) that may conflict with DFF.
Don't use triggers or triggered rules that do URL redirect at login. It was possible earlier but not any more of some reason caused by Facebook...
You may need to add some few lines to the fb.js and fb_connect.js files.
Comment #2
botanic_spark commentedThanks for fast reply.
I do have login destination module which is necessary for my site. I think that's causing logout issue when i am connected to facebook.
How should i manage these redirections? Is there any other way?
Comment #3
miccelito commentedI don't think it would cause logout issues, if the mentioned module would cause problems that would be login issues, but seems that you don't have any login issues, do you? You have to explain your logout issue (clickhandler issue? infinite loop issue?) to be able to suggest any solution.
Comment #4
botanic_spark commentedMy issue is when i click logout, it takes me to page that i put as login destination and doesn't logges me out. Then i have to click logout again, and only then it's successful.
So i have to click twice to be logged out.
Comment #5
miccelito commentedClick handler issue then. You could try to disable few lines (see bold lines below) in DFF's fb_connect.js and see if that solves your issue.
Around line 69
Comment #6
botanic_spark commentedAs soon as i switch to fb cookie, i can't logout at all. :(
I tried to remove that part of code, but no changes.
It logges me out of Facebook, but i keep being logged in on drupal.
Comment #7
miccelito commentedDid you also clear cache after changing in js file?
Comment #8
botanic_spark commentedYes. Cache, cookies, everything.
Comment #9
miccelito commentedI mean did you clear Drupal's cache (Site configuration -> Performance -> Clear cache) ? Better ask to be sure of your answer...
Comment #10
botanic_spark commentedOf course. Cleared everything.
Comment #11
miccelito commentedYou could try to temporary disable that mentioned module Login Destination to see if it's conflicting...
Comment #12
botanic_spark commentedI also tried that. It sends me to user page after logout, and i'm still logged in.
Comment #13
miccelito commentedHmmm... well... As the DFF's maintainer Dave Cohen mentioned once, the solutions can be individual for each user no matter they're using same DFF versions etc.
So..
You're using DFF 6.x-3.2-rc3 and latest Facebook PHP SDK 3.1.1 (release update 2012-01-25).
You did disable Login Destination and have no URL redirect triggers/triggered rules activated for logout.
DFF settings as mentioned in my comment #1.
Added the change to fb_connect.js as mentioned in my comment #5.
Cleared Drupal's cache.
All those together and still have logout problem. Right?
Well..
Besides the above stuff you might also try this:
1. In DFF 'User Settings' uncheck '[ ] Validate session' .
2. Use amatech's fix (http://drupal.org/node/1423730#comment-5557270) for fb.js
Rename the current fb.js in your /modules/fb/ folder to i.e fb-OLD.js and upload the new fb.js (http://drupal.org/files/fb.js_.txt saved as fb.js)
3. And in settings.php you would have at least these lines added:
Comment #14
Dave Cohen commentedThe idea behind "use fb cookie" is to use the same cookie that facebook's php sdk and javascript sdk use. Recommended.
The idea behind "store in session" is to get around problems when third-party cookies are disabled. Problem is each browser handles third party cookies a little differently. I'm not convinced this works 100% as it should.
You should be able to enable them both, and it should just work. Famous last words.
I'm not sure why you can't log out easily. Try firebug and look for javascript errors. Try to narrow down exactly which browsers have a problem. All?