php - non-dev user always has ID 0 -
i have ran serious problem must resolved before continuing development.
my boss created app, him works expected - user logged in, data accessible, works. every other user, $facebook->getuser() returns 0, no matter what. obviously, i'm logged facebook, there login link in app, clicking doesn't work, nothing changes.
this problem occurs users not in way connected app!
i confirmed developer request app few days ago , works account, before did not work, not me, not other user tried, no matter if app public or in dev mode, technically shouldn't matter authentication.
we tried many things, existing code shared on internet, code bottom of article: http://www.thegeekstuff.com/2014/03/develop-facebook-app/ (with our own app id , secret, of course) not changed anything, give ready code example.
even if deleted below "$user = $facebook->getuser();" , put echo $user; die();
after that, showed user id 0.
another thing i've noticed might in solving problem following: same code article, boss' session contains several variables @ times, when open app non-dev user, @ first there "fb_app-id_state" variable, , when refresh page, gets deleted , session empty. if refresh page again, variable created again different value, refresh , it's gone again, , on.
after day of trying shit work php, switched js sdk. apparently doesn't work, however, have yet receive specifics boss since don't have fake account test myself.
the obvious question is: going on , why isn't authentication working expected?
edit: code - http://pastebin.com/qcptfths
you need looking app settings. owner, app admin, dev, can use aplication on sandbox mode. other users app dont work or work buggy. remove test mode, , put out app in live mode.
Comments
Post a Comment