views:

33

answers:

2

I am making my first Facebook App and nothing is working as stated in the documentation. As an example, I have facebook.php on my server and am calling this line:

$friends = $facebook->api_client->friends_get();

but I get a "call to undefined function friends_get()"

I see that there is no "friends_get()" function in the facebook.php. I do see there is a friends.get in that long array... but I'm not sure how to access it?

+1  A: 

Hi There,

I think you have downloaded the new facebook library but trying code from the old documentation. Make sure:

  1. You have downloaded the PHP SDK from here: http://github.com/facebook/php-sdk/
  2. You are reading this guide: http://developers.facebook.com/docs/

If you are stuck, have a look at this blog post which gives a short intro to the new SDK.

phpfour
A: 

Hi, but there is no definition of api_client in facebook.php. I have the same issue...

Having same problem and becoming desperate:)

Roman