Skip to content

Commit

Permalink
link rel=image_src for facebook
Browse files Browse the repository at this point in the history
  • Loading branch information
xho committed Jan 15, 2015
1 parent cd98fe3 commit 8586aa0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bedita-app/views/helpers/be_front.php
Original file line number Diff line number Diff line change
Expand Up @@ -242,10 +242,13 @@ public function metaOg() {

// TODO: alternative og:image if poster is empty and there is a multimedia image in relations
if (!empty($object['relations']['poster'])) {
$imgUri = Configure::read('mediaUrl') . $object['relations']['poster'][0]['uri'];
$html .= "\n" . $this->Html->meta(array(
'property' => 'og:image',
'content' => Configure::read('mediaUrl') . $object['relations']['poster'][0]['uri']
'content' => $imgUri
));

$html .= "\n" . '<link rel="image_src" type="image/jpeg" href="' . $imgUri . '" />';
}

// og:description
Expand Down

0 comments on commit 8586aa0

Please sign in to comment.