Created
March 20, 2014 17:02
-
-
Save good/9668709 to your computer and use it in GitHub Desktop.
Custom meta description based on page content for Kirby
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php snippet('header', array('section' => 'journal', 'title' => $page->title(), 'customdesc' => $page->text())); ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<meta name="description" content="<?php if(isset($customdesc)) { echo html($customdesc); } else { echo html($site->description()); } ?>" /> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment