|
@@ 1337-1345 (lines=9) @@
|
| 1334 |
|
} |
| 1335 |
|
|
| 1336 |
|
// If I want to add a share block in my view |
| 1337 |
|
if ($game->getFbShareMessage()) { |
| 1338 |
|
$fbShareMessage = $game->getFbShareMessage(); |
| 1339 |
|
} else { |
| 1340 |
|
$fbShareMessage = str_replace( |
| 1341 |
|
'__placeholder__', |
| 1342 |
|
$game->getTitle(), |
| 1343 |
|
$this->getOptions()->getDefaultShareMessage() |
| 1344 |
|
); |
| 1345 |
|
} |
| 1346 |
|
|
| 1347 |
|
if ($game->getFbShareImage()) { |
| 1348 |
|
$fbShareImage = $this->frontendUrl()->fromRoute( |
|
@@ 1385-1393 (lines=9) @@
|
| 1382 |
|
); |
| 1383 |
|
} |
| 1384 |
|
|
| 1385 |
|
if ($game->getTwShareMessage()) { |
| 1386 |
|
$twShareMessage = $game->getTwShareMessage().$socialLinkUrl; |
| 1387 |
|
} else { |
| 1388 |
|
$twShareMessage = str_replace( |
| 1389 |
|
'__placeholder__', |
| 1390 |
|
$game->getTitle(), |
| 1391 |
|
$this->getOptions()->getDefaultShareMessage() |
| 1392 |
|
).$socialLinkUrl; |
| 1393 |
|
} |
| 1394 |
|
|
| 1395 |
|
$ogTitle = new \PlaygroundCore\Opengraph\Tag('og:title', $fbShareMessage); |
| 1396 |
|
$ogImage = new \PlaygroundCore\Opengraph\Tag('og:image', $fbShareImage); |