I'm using this code for the app authentication:
//Obtain the access_token with publish_stream permission
if(empty($_REQUEST["code"])){
$dialog_url= "http://www.facebook.com/dialog/oauth?"
. "client_id=" . $app_id
. "&redirect_uri=" . urlencode($post_login_url)
. "&scope=publish_stream,user_birthday";
echo("<script>top.location.href='" . $dialog_url
. "'</script>");
}
else {
$code = $_REQUEST["code"];
$token_url="https://graph.facebook.com/oauth/access_token?"
. "client_id=" . $app_id
. "&client_secret=" . $app_secret
. "&code=" . $code
. "&redirect_uri=" . urlencode($post_login_url);
$response = file_get_contents($token_url);
$params = null;
parse_str($response, $params);
$access_token = $params['access_token'];
}
In the new facebook authentication, the user have the option to choose one of the permission request and cancel it after he click on "Log in" button. for example, the user can disable the request for publish_stream or user_birthday access and still to log into my app. I saw that Zynga and many others still using the old authentication request that looks like:
http://i.stack.imgur.com/ESigT.png (some picture that I've found in the net)
but for some reason in the last 2 weeks my request for permission dialog got changed to the new one: http://i52.tinypic.com/qstm6g.png (some picture that I've found in the net)
How can I switch it back to the old permission dialog? that is only 1 single dialog box and not 2-3 dialog box till the user get logged into my app.