You are here

public function FBAutopostEntity::remoteEntityEdit in Facebook Autopost 7

Edits a publication in facebook from a stored entity.

Parameters

FacebookPublicationEntity $publication: The fully loaded Facebook publication entity

Throws

FBAutopostException

See also

FBAutopost::remoteEdit()

1 method overrides FBAutopostEntity::remoteEntityEdit()
FBAutopostEntityEvent::remoteEntityEdit in fb_autopost_entity/class/FBAutopostEntityEvent.php
Edits a publication in facebook from a stored entity. Events in Facebook can actually be updated, this means that there is no deletion needed.

File

fb_autopost_entity/class/FBAutopostEntity.php, line 74
Handles the Entity publication.

Class

FBAutopostEntity
Handles publishing using a Facebook publication entity.

Code

public function remoteEntityEdit(FacebookPublicationEntity $publication) {

  // In this case, edit means delete + publish. This has the side effect that
  // the ID is not preserved.
  if ($this
    ->remoteEntityDelete($publication)) {
    return $this
      ->publishEntity($publication);
  }
}