hello,
i wanna define Open Graph Meta data for every page, whats the best way to do it?
hello,
i wanna define Open Graph Meta data for every page, whats the best way to do it?
Check out the open graph protocol: http://ogp.me
Thanks I know the page My question is how to define individual data for some pages?
I searched in this forum for youβ¦
There I have found something, where you may find a hint to your question in
and following itβs link to
https://github.com/julien-gargot/kirby-devkit/blob/master/site/snippets/header.php
Good luck!
This article is written in german, but maybe the code-snippet with the OpenGraph tags is still helpful for your request.
https://www.mariussonnentag.de/kirby-cms-seo-optimieren/
<!-- Begin OpenGraph Tags for Facebook & Co. -->
<meta name="DC.Title" content="<?php echo html($page->title()) ?>" />
<meta name="DC.Creator" content="<?php echo html($site->author()) ?>" />
<meta name="DC.Rights" content="<?php echo html($site->author()) ?>" />
<meta name="DC.Publisher" content="<?php echo html($site->author()) ?>" />
<meta name="DC.Description" content="<?php echo html($page->description()) ?>"/ >
<meta name="DC.Language" content="de_DE" />
<meta property="og:title" content="<?php echo html($page->title()) ?> | <?php echo html($site->title()) ?>" />
<meta property="og:type" content="website" />
<meta property="og:url" content="<?php echo html($site->url()) ?>" />
<meta property="og:image" content="<?php echo url('assets/images/facebook/facebook-icon-646x1027.jpg') ?>" />
<meta property="og:description" content="<?php echo html($page->description()) ?>" />
<meta itemprop="name" content="<?php echo html($page->title()) ?> | <?php echo html($site->title()) ?>">
<meta itemprop="description" content="<?php echo html($page->description()) ?>">