|Project:||Drupal for Facebook|
$url = "https://www.facebook.com/dialog/oauth?client_id=306583906119415&redirect_uri=http://domain-name.com/&scope=$perms&response_type=token";
$button = "<a href='$url'>Login with facebook</a>";
Now when i click on this link, it works just fine in terms of connecting to facebook, but after the user authorize the application and Facebook redirect you to the website. It does not auto login at the site, and you have to click again on the "Login with facebook" link and to login you in.
Do you know how to do this correctly? or what i should set my facebook redirect url as?