provided there’s no implications (looks like there won’t be) I’d be hapy to add that.
I’m not sure about the yarpp_map_post_types, haven’t dug into yarpp ever, but if you can hook into yarp, probably you can do this. My guess is you’d be wanting to filter by postmeta _event_start_ts
Julie I was looking for the exact same thing! A bit of jiggery pokery and I managed to get the YARPP template working (yarpp-template-thumbnail.php) to show only current and future events. I’m using the thumbnail template and I’ve replaced it with my own code to show the related posts as thumbnails – but it’s only the event date element that you’ll need to use. Not quite the same as filtering to remove past events, but it does the same job.
Here’s the code:
<?php
global $post;
$EM_Event = em_get_event($post->ID, 'post_id');
?>
<h3 class="sub">Similar Events</h3>
<?php if (have_posts()):?>
<?php while (have_posts()) : the_post();
$EM_Event = em_get_event($post->ID, 'post_id');
$eventdate = date('Y-m-d', $EM_Event->start);
$today = date('Y-m-d',current_time('timestamp')); ?>
<?php if ($eventdate >= $today):?>
<ul id='related_posts_thumbnails'>
<li>
<?php $d = date_i18n(get_option('dbem_date_format'), $EM_Event->start); ?><?php $t = date_i18n(get_option('time_format'), $EM_Event->start) ; ?>
<a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_post_thumbnail('270x150'); ?><span><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title_attribute(); ?><br />
<p class="left"><?php echo $d ; ?></p><p class="right"><?php echo $t ; ?> </p>
</a></a></span></li>
</ul>
<?php endif; ?>
<?php endwhile; ?>
<?php else: ?>
<p>No similar events...</p>
<?php endif; ?>