Services_Facebook
[ class tree: Services_Facebook ] [ index: Services_Facebook ] [ all elements ]

Class: Services_Facebook_Feed

Source Location: /Services_Facebook-0.1.0/Services/Facebook/Feed.php

Class Overview

Services_Facebook_Common
   |
   --Services_Facebook_Feed

Facebook Feed Interface


Author(s):

Methods


Inherited Variables

Inherited Methods


Class Details

[line 32]
Facebook Feed Interface


[ Top ]


Method Detail

publishActionOfUser   [line 131]

boolean publishActionOfUser( string $title, [string $body = ''], [array $images = array()])

Publish an action to a user's feed

An action differs from a story in that a user's action is sent to all of that user's friends as well.

The $images array should be a numerically indexed array of arrays, where each image has two keys: src and href. The src is the full URI of the image and the href is the link of that image.

  1.  <?php
  2.  $images = array(
  3.      array('src'  => 'http://example.com/images1.jpg',
  4.            'href' => 'http://example.com/images.php?image=1'),
  5.      array('src'  => 'http://example.com/images2.jpg',
  6.            'href' => 'http://example.com/images.php?image=2'),
  7.      array('src'  => 'http://example.com/images3.jpg',
  8.            'href' => 'http://example.com/images.php?image=3')
  9.  );
  10.  ?>


Parameters:

string   $title   —  FBML to post as story title
string   $body   —  FBML to post as story body
array   $images   —  Images to post to story entry

[ Top ]

publishStoryToUser   [line 63]

boolean publishStoryToUser( string $title, [string $body = ''], [array $images = array()])

Publish a story to a user's feed

The $images array should be a numerically indexed array of arrays, where each image has two keys: src and href. The src is the full URI of the image and the href is the link of that image.

  1.  <?php
  2.  $images = array(
  3.      array('src'  => 'http://example.com/images1.jpg',
  4.            'href' => 'http://example.com/images.php?image=1'),
  5.      array('src'  => 'http://example.com/images2.jpg',
  6.            'href' => 'http://example.com/images.php?image=2'),
  7.      array('src'  => 'http://example.com/images3.jpg',
  8.            'href' => 'http://example.com/images.php?image=3')
  9.  );
  10.  ?>


Parameters:

string   $title   —  FBML to post as story title
string   $body   —  FBML to post as story body
array   $images   —  Images to post to story entry

[ Top ]

publishTemplatizedAction   [line 206]

boolean publishTemplatizedAction( string $titleTemplate, [array $feedData = array()], [array $images = array()])

Publish a templatized action to a user's feed

An action differs from a story in that a user's action is sent to all of that user's friends as well.

An templatized story publishes News Feed stories to the friends of that user. These stories or more likely to appear to the friends of that user depending upon a variety of factors, such as the closeness of the relationship between the users, the interaction data facebook has about that particular story type, and the quality of the content in the story/on the linked page. http://wiki.developers.facebook.com/index.php/FeedRankingFAQ

The $images array should be a numerically indexed array of arrays, where each image has two keys: src and href. The src is the full URI of the image and the href is the link of that image.

  1.  <?php
  2.  $images = array(
  3.      array('src'  => 'http://example.com/images1.jpg',
  4.            'href' => 'http://example.com/images.php?image=1'),
  5.      array('src'  => 'http://example.com/images2.jpg',
  6.            'href' => 'http://example.com/images.php?image=2'),
  7.      array('src'  => 'http://example.com/images3.jpg',
  8.            'href' => 'http://example.com/images.php?image=3')
  9.  );
  10.  ?>


Parameters:

string   $titleTemplate   —  FBML to post as the title, must contain {actor}
array   $feedData   —  Array containing optional Feed template, data, and/or actor id
array   $images   —  Images to post to story entry

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:19:43 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.