First, I'd like to say this isn't a general question on the Facebook php/javascript sdk. I've successfully added the "Facebook login button" to a few little test projects.
My question is, what is the best way to show the user is wanting to log in with Facebook. Just because someone is logged in to Facebook when the visit my site, doesn't necessarily mean they want to login to my site with Facebook.
I know that after authorizing the user with a FB app, it redirects with a variety of $_GET
variables, but if my user is returning to my site, and has already authorized my app, how can I create a "Facebook Login" button that basically 'says' If user clicks this button, pull Facebook user_profile, and use their info for login, else require Facebook login as normal
.
I know I could create a button, forward to a page, set a session var, and redirect to the main page, but I'd like to create this effect without noticeable redirections; no redirections if possible.