Skip to content

Instantly share code, notes, and snippets.

@bastianallgeier
Last active August 29, 2015 14:09
Show Gist options
  • Save bastianallgeier/cbb44be87526b9f438cf to your computer and use it in GitHub Desktop.
Save bastianallgeier/cbb44be87526b9f438cf to your computer and use it in GitHub Desktop.
<?php
$results = new Pages();
$children = $pages->find('webfonts-in-action')->children();
foreach($page->fontnames()->split(',') as $fontname) {
$results->add($children->filterBy('fontnames', $fontname, ','));
}
foreach($results->shuffle()->limit(3) as $result): ?>
<!-- your html for each result here -->
<?php endforeach; ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment