I am a newbie for facebook apps…Just now starting with some basic code got from sites…I created a new app and did everything, but when I use the URL generated by the getLoginurl(), it says “An error occurred. Please try again later.” Here is the code which I am using, kindly let me know where I am going wrong..
if ($user) {
$logoutUrl = $facebook->getLogoutUrl();
} else {
$loginUrl = $facebook->getLoginUrl();
}
Is the website or canvas URL configured in your app settings correct?
If not, because the value returned by getLoginUrl() includes a
redirect_uriparameter set to the current page’s URL, you’ll get that error.