Skip to content

Instantly share code, notes, and snippets.

@bastianallgeier
Forked from niklausgerber/test
Created September 27, 2012 11:04
Show Gist options
  • Save bastianallgeier/3793470 to your computer and use it in GitHub Desktop.
Save bastianallgeier/3793470 to your computer and use it in GitHub Desktop.
Can this be done more cleverly - and it does not work
<?php $article = $pages->find('blog')->children()->last() ?>
<section>
<h2 class="nav-element"><a href="<?php echo html($article->url()) ?>"><?php echo html($article->title()) ?></a></h2>
<p><?php echo excerpt($article->text(), 300) ?> <a href="<?php echo html($article->url()) ?>">Read more</a></p>
</section>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment