CakePHP-Facebook-Plugin
CakePHP-Facebook-Plugin copied to clipboard
any kind of "redirect" cannot use in function options
I have a issue when I uses the plugin, I cannot use "redirect" in Helper Facebook::login() and logout(). I also can not use function afterFacebookLogin() to redirect, the app will only redirect only if I refresh the page.
Example when my code in view is:
Facebook->logout(array('redirect' => array('controller' => 'users', 'action' => 'logout'))); ?>===> my logout button disappears.
when I debug(Router::url($options['redirect']));
this show the wrong url. May be any wrong when I config?
Any Suggestion for me?
try this way:
Facebook->logout(array('redirect' => 'logout'', 'label' => 'Logout')); ?>if you want to put an image instead text try this way
Facebook->logout(array('redirect' => 'logout'', 'label' => 'Logout', 'img' => 'connectwithfacebook.gif')); ?>