a facebook app question

Posted by Robert on Stack Overflow See other posts from Stack Overflow or by Robert
Published on 2010-05-10T01:12:51Z Indexed on 2010/05/10 1:18 UTC
Read the original article Hit count: 371

Filed under:

I have written a small app and put it on facebook. I got an application ID and secret. Then I wrote the following script to access my app (just as told on the facebook page).

<?php

require './src/facebook.php';

$facebook = new Facebook(array(
  'appId'  => 'xxxx',
  'secret' => 'xxxx',
  'cookie' => true, // enable optional cookie support
));

try {
  $me = $facebook->api('/me');
} catch (FacebookApiException $e) {
  error_log($e);
}


if ($facebook->getSession()) {
  echo '<a href="' . $facebook->getLogoutUrl() . '">Logout</a>';
} else {
  echo '<a href="' . $facebook->getLoginUrl() . '">Login</a>';
}


?>

Then I started running this script. It prompted me with the login link, then took me to the facebook login page. However, after I enter my facebook login details, I get this error page:

Error.

API Error Code: 100 API Error
Description: Invalid parameter Error
Message: next is not owned by the application.

Could anyone help me a little bit please, I am really confused here about what's going on.

© Stack Overflow or respective owner

Related posts about facebook-api