Support » Plugins » An upcoming events list

  • Here’s what I’m using:

    Here’s the code:

    <?php // Get today's date in the right format
    $todaysDate = date('m/d/Y');
    <?php query_posts('showposts=4&category_name=events&meta_key=date&meta_compare=>=&meta_value=' . $todaysDate . '&orderby=meta_value&order=ASC'); ?>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    	<span class="event-title"><?php echo get_post_meta($post->ID, "date", true); ?> <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></span> <span class="event-excerpt"><?php the_excerpt(); ?></span>
    <?php endwhile; else: ?>
    <li>Check back soon for more upcoming events!</li>
    <?php endif; ?>
    <li><a href="/calendar">More events</a></li>
    <?php wp_reset_query(); ?>

    But as of Jan. 1, events from 2010 are showing up as future events? Any ideas why? See: for live example

  • The topic ‘An upcoming events list’ is closed to new replies.