Joomla Platform  13.1
Documentation des API du framework Joomla Platform
 Tout Classes Espaces de nommage Fichiers Fonctions Variables Pages
Référence de la classe JFacebookPhoto
+ Graphe d'héritage de JFacebookPhoto:
+ Graphe de collaboration de JFacebookPhoto:

Liste de tous les membres

Fonctions membres publiques

 getPhoto ($photo)
 getComments ($photo, $limit=0, $offset=0, $until=null, $since=null)
 createComment ($photo, $message)
 deleteComment ($comment)
 getLikes ($photo, $limit=0, $offset=0, $until=null, $since=null)
 createLike ($photo)
 deleteLike ($photo)
 getTags ($photo, $limit=0, $offset=0, $until=null, $since=null)
 createTag ($photo, $to=null, $tag_text=null, $x=null, $y=null)
 updateTag ($photo, $to, $x=null, $y=null)
 getPicture ($photo, $redirect=true)
- Fonctions membres publiques inherited from JFacebookObject
 __construct (JRegistry $options=null, JHttp $client=null, JFacebookOAuth $oauth=null)
 sendRequest ($path, $data= '', array $headers=null, $limit=0, $offset=0, $until=null, $since=null)
 get ($object)
 getConnection ($object, $connection=null, $extra_fields= '', $limit=0, $offset=0, $until=null, $since=null)
 createConnection ($object, $connection=null, $parameters=null, array $headers=null)
 deleteConnection ($object, $connection=null, $extra_fields= '')
 setOAuth ($oauth)
 getOAuth ()

Additional Inherited Members

- Fonctions membres protégées inherited from JFacebookObject
 fetchUrl ($path, $limit=0, $offset=0, $until=null, $since=null)
- Attributs protégés inherited from JFacebookObject
 $options
 $client
 $oauth

Description détaillée

Définition à la ligne 23 du fichier photo.php.


Documentation des fonctions membres

JFacebookPhoto::createComment (   $photo,
  $message 
)

Method to comment on a photo. Requires authentication and publish_stream permission, user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
string$messageThe comment's text.
Renvoie:
mixed The decoded JSON response or false if the client is not authenticated.
Depuis:
13.1

Définition à la ligne 67 du fichier photo.php.

{
// Set POST request parameters.
$data['message'] = $message;
return $this->createConnection($photo, 'comments', $data);
}
JFacebookPhoto::createLike (   $photo)

Method to like a photo. Requires authentication and publish_stream permission, user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
Renvoie:
boolean Returns true if successful, and false otherwise.
Depuis:
13.1

Définition à la ligne 116 du fichier photo.php.

{
return $this->createConnection($photo, 'likes');
}
JFacebookPhoto::createTag (   $photo,
  $to = null,
  $tag_text = null,
  $x = null,
  $y = null 
)

Method to tag one or more Users in a photo. $to or $tag_text required. Requires authentication and publish_stream permission, user_photos permission for private photos.

Paramètres:
string$photoThe photo id.
mixed$toID of the User or an array of Users to tag in the photo: [{"id":"1234"}, {"id":"12345"}].
string$tag_textA text string to tag.
integer$xx coordinate of tag, as a percentage offset from the left edge of the picture.
integer$yy coordinate of tag, as a percentage offset from the top edge of the picture.
Renvoie:
boolean Returns true if successful, and false otherwise.
Depuis:
13.1

Définition à la ligne 167 du fichier photo.php.

{
// Set POST request parameters.
if (is_array($to))
{
$data['tags'] = $to;
}
else
{
$data['to'] = $to;
}
if ($tag_text)
{
$data['tag_text'] = $tag_text;
}
if ($x)
{
$data['x'] = $x;
}
if ($y)
{
$data['y'] = $y;
}
return $this->createConnection($photo, 'tags', $data);
}
JFacebookPhoto::deleteComment (   $comment)

Method to delete a comment. Requires authentication and publish_stream permission, user_photos or friends_photos permission for private photos.

Paramètres:
string$commentThe comment's id.
Renvoie:
boolean Returns true if successful, and false otherwise.
Depuis:
13.1

Définition à la ligne 84 du fichier photo.php.

{
return $this->deleteConnection($comment);
}
JFacebookPhoto::deleteLike (   $photo)

Method to unlike a photo. Requires authentication and publish_stream permission, user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
Renvoie:
boolean Returns true if successful, and false otherwise.
Depuis:
13.1

Définition à la ligne 130 du fichier photo.php.

{
return $this->deleteConnection($photo, 'likes');
}
JFacebookPhoto::getComments (   $photo,
  $limit = 0,
  $offset = 0,
  $until = null,
  $since = null 
)

Method to get a photo's comments. Requires authentication and user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
integer$limitThe number of objects per page.
integer$offsetThe object's number on the page.
string$untilA unix timestamp or any date accepted by strtotime.
string$sinceA unix timestamp or any date accepted by strtotime.
Renvoie:
mixed The decoded JSON response or false if the client is not authenticated.
Depuis:
13.1

Définition à la ligne 52 du fichier photo.php.

{
return $this->getConnection($photo, 'comments', '', $limit, $offset, $until, $since);
}
JFacebookPhoto::getLikes (   $photo,
  $limit = 0,
  $offset = 0,
  $until = null,
  $since = null 
)

Method to get photo's likes. Requires authentication and user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
integer$limitThe number of objects per page.
integer$offsetThe object's number on the page.
string$untilA unix timestamp or any date accepted by strtotime.
string$sinceA unix timestamp or any date accepted by strtotime.
Renvoie:
mixed The decoded JSON response or false if the client is not authenticated.
Depuis:
13.1

Définition à la ligne 102 du fichier photo.php.

{
return $this->getConnection($photo, 'likes', '', $limit, $offset, $until, $since);
}
JFacebookPhoto::getPhoto (   $photo)

Method to get a photo. Requires authentication and user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
Renvoie:
mixed The decoded JSON response or false if the client is not authenticated.
Depuis:
13.1

Définition à la ligne 34 du fichier photo.php.

{
return $this->get($photo);
}
JFacebookPhoto::getPicture (   $photo,
  $redirect = true 
)

Method to get the album-sized view of the photo. Requires authentication and user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
boolean$redirectIf false this will return the URL of the picture without a 302 redirect.
Renvoie:
string URL of the picture.
Depuis:
13.1

Définition à la ligne 238 du fichier photo.php.

{
$extra_fields = '';
if ($redirect == false)
{
$extra_fields = '?redirect=false';
}
return $this->getConnection($photo, 'picture', $extra_fields);
}
JFacebookPhoto::getTags (   $photo,
  $limit = 0,
  $offset = 0,
  $until = null,
  $since = null 
)

Method to get the Users tagged in the photo. Requires authentication and user_photos or friends_photos permission for private photos.

Paramètres:
string$photoThe photo id.
integer$limitThe number of objects per page.
integer$offsetThe object's number on the page.
string$untilA unix timestamp or any date accepted by strtotime.
string$sinceA unix timestamp or any date accepted by strtotime.
Renvoie:
mixed The decoded JSON response or false if the client is not authenticated.
Depuis:
13.1

Définition à la ligne 148 du fichier photo.php.

{
return $this->getConnection($photo, 'tags', '', $limit, $offset, $until, $since);
}
JFacebookPhoto::updateTag (   $photo,
  $to,
  $x = null,
  $y = null 
)

Method to update the position of the tag for a particular Users in a photo. Requires authentication and publish_stream permission, user_photos permission for private photos.

Paramètres:
string$photoThe photo id.
string$toID of the User to update tag in the photo.
integer$xx coordinate of tag, as a percentage offset from the left edge of the picture.
integer$yy coordinate of tag, as a percentage offset from the top edge of the picture.
Renvoie:
boolean Returns true if successful, and false otherwise.
Depuis:
13.1

Définition à la ligne 210 du fichier photo.php.

{
// Set POST request parameters.
$data['to'] = $to;
if ($x)
{
$data['x'] = $x;
}
if ($y)
{
$data['y'] = $y;
}
return $this->createConnection($photo, 'tags', $data);
}

La documentation de cette classe a été générée à partir du fichier suivant :