FriendsOfSymfony / FOSFacebookBundle

NOT MAINTAINED - see https://github.com/hwi/HWIOAuthBundle
321 stars 140 forks source link

FOSFacebookBundle works, but FOSUserBundle does not seem to work #170

Open sukhrobkhakimov opened 12 years ago

sukhrobkhakimov commented 12 years ago

I can login with FOSFacebookBundle and everything works. But, FOSUserBundle does not seem to work because profiler shows Username: anon and Roles: {}. And, there is no user data about logged in user in database. Maybe, I didn't understand how it works. Please, help.

Please, see my post in stackoverflow http://stackoverflow.com/questions/11619245/fosfacebookbundle-works-but-fosuserbundle-does-not-seem-to-work

drgomesp commented 12 years ago

Answered on stackoverflow.

Chrysweel commented 12 years ago

I don't understand, where I have to include my controller and my route. I am using, FOSUserBundle and FOSFacebookBundle. ¿ Where have I to write the action?

public function loginFacebookAction()
{
    return array();
}

I have in my app/config/routing.yml :

_security_check:
    pattern:  /login_check
_security_logout:
    pattern:  /logout

But in this routes doesn't include its controller ( defaults: {_controller: Bundle:name:function }

I think that I don't understand how use the FOSFacebookBundle.

Someone can help me please!! ; )

stof commented 12 years ago

@Chrysweel the login_check and logout url don't need a controller. They are handled by the firewall