I am having an issue with my source code. When I run it, I receive an alert that says "No Response" and then the Facebook page displays an error message stating "An error occurred with MYAPP. Please try again later"
<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js" charset="utf-8"></script>
<script>
FB.init({appId: 'MYAPPID',status: true, cookie:true, xfbml: true});
</script>
<script>
FB.getLoginStatus(function(response){
if(!response.session){
alert("NO RESPONSE");
top.location.href="http://www.facebook.com/dialog/oauth?client_id=MYAPPID&redirect_uri=http://MYWEBSITE";
}
});
I'm not sure where the mistake is in my code.
Thank you for your help.
The following error has now appeared:
API Error Code: 191
API Error Description: The specified URL is not owned by the application
Error Message: Invalid redirect_uri: Given URL is not allowed by the Application configuration.