FezBook

Class FezBook

Description

A library of functions I found useful to use Facebook's Graph API.

Example

$t = /* your access_token */;
$fbid = /* facebook id to post to */;
$postdata = "access_token=".$t;
$postdata .= "&link=".$link;
$postdata .= "&name=".urlencode(strip_tags($post_title));
$postdata .= "&caption=".urlencode($caption);
$postdata .= "&description=".urlencode($desc);
$fb = new FezBook();
$fbpost = $fb->post_to_feed($t,$postdata,$fbid);

Notes

If no Facebook ID is passed into any of the functions, it will default to "me" (https://graph.facebook.com/me)

phpdoc Dump

Description | Vars (details) | Methods (details)
Located in /fezbook.php (line 9)


Variable Summary
mixed $graph

Method Summary
FezBook __construct ()
void curl ( $uri, [ $method = null], [ $postdata = null])
void get_accounts ( $token, [ $fbid = null])
void get_fbdata ( $token, [ $fbid = null])
void get_feed ( $token, [ $fbid = null])
void post_to_feed ( $token,  $postdata, [ $fbid = null])

Variables

mixed $graph = 'https://graph.facebook.com/' (line 10)
  • access: public

Methods

Constructor __construct (line 12)
FezBook __construct ()

curl (line 31)
void curl ( $uri, [ $method = null], [ $postdata = null])
  • $uri
  • $method
  • $postdata

get_accounts (line 60)
void get_accounts ( $token, [ $fbid = null])
  • $token
  • $fbid

get_fbdata (line 85)
void get_fbdata ( $token, [ $fbid = null])
  • $token
  • $fbid

get_feed (line 105)
void get_feed ( $token, [ $fbid = null])
  • $token
  • $fbid

post_to_feed (line 125)
void post_to_feed ( $token,  $postdata, [ $fbid = null])
  • $token
  • $postdata
  • $fbid
Documentation generated on Thu, 09 Feb 2012 10:39:27 -0500 by phpDocumentor 1.4.4

No comments: