Skip to content

Instantly share code, notes, and snippets.

@kalico1
Created April 15, 2017 03:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kalico1/82bd9f5b1226a252047babaa2f295c10 to your computer and use it in GitHub Desktop.
Save kalico1/82bd9f5b1226a252047babaa2f295c10 to your computer and use it in GitHub Desktop.
Template used with [eab_archive]
<?php
// template used to display shortcode lists e.g., [eab_archive template="event-list-with-thumbnails"] also works with [eab_expired] //
?>
<?php
if ($events) {
foreach ($events as $event) {
?>
<section class="eab-events-archive <?php esc_attr_e($args['class']); ?>">
<?php $event = $event instanceof Eab_EventModel ? $event : new Eab_EventModel($event); ?>
<article class="eab-event <?php echo eab_call_template('get_status_class', $event); ?>" id="eab-event-<?php echo $event->get_id(); ?>">
<div class="event-listing">
<span class="event-listing-thumbnail"><?php echo $event->get_featured_image(); ?></span>
<span class="event-listing-title"><?php echo $event->get_title(); ?></span>
<span class="event-listing-meta"><?php echo eab_call_template('get_archive_content', $event); ?></span>
<span class="event-listing-excerpt"><?php echo $event->get_excerpt_or_fallback(300); ?></span>
</div>
</article>
</section>
<?php }
} else { ?>
<!--
<p><img src="http://XXXXXXX.org/resources/wp-content/uploads/sites/23/2016/08/MMCollage.jpg" width="200" class="alignleft size-thumbnail">There are no upcoming webinars listed at this time. Please browse the tabs on this page for other webinars that may be of interest to you, and check back soon.</p><p> We present a webinar every month, so it will be posted soon.</p>
-->
<?php }
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment