random_featured_collection
randomly returns one Collection object that has been marked featured.
Usage
<?php random_featured_collection(); ?>
Examples
The following example sets a variable $collection
to a random featured collection, which can then be used in other functions.
<?php $collection = random_featured_collection(); ?>
Taking the above example a few steps further, we can display metadata from the random featured collection by setting it as the current collection, then using the collection helper to display a specific field:
<?php $collection = random_featured_collection(); set_current_collection($collection); echo '<h2>'.collection('Name').'</h2>'; ?>