• Resolved stevebrett

    (@stevebrett)


    Ive just upgrade the The Events calendat 2.05 and need help re-writing a custom loop I have in my home page. I cobbled this together using examples from the forums but really dont know where to beging to get it working with the upgrade.

    What i had was this – which displayed events in the future only
    Hope someone can help clean this up for me. Thnaks

    <?php
    $todaysDate = date('Y-m-d G:i:s', strtotime('-1 days'));
    $recentPosts = new WP_Query();
    $recentPosts->query('showposts=5&category_name=Events&meta_key=_EventStartDate&meta_compare=>=&meta_value='.$todaysDate.'&orderby=_EventStartDate&order=ASC');
    ?>
    <?php while ($recentPosts->have_posts()) : $recentPosts->the_post(); ?>
    <div class="hp_post">
    <div class="post_thumb">
    <?php if ( has_post_thumbnail()) : ?>
    <a>" title="<?php the_title_attribute(); ?>" >
    <?php the_post_thumbnail(array (100,100)); ?>
    </a>
    <?php endif; ?>

    https://www.ads-software.com/extend/plugins/the-events-calendar/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hey Steve. Are you saying this stopped working when you updated to 2.0.5? Was that because you’d modified the core plugin, or something else?

    I will say that our template tag and loop documentation at https://tri.be/support/documentation should point you in the right direction here. Want to give it a go and let me know if you still have questions from there?

    Thread Starter stevebrett

    (@stevebrett)

    Sorry I should have reposted – I got the loop working again by changing query to select on post_type=tribe_events as opposed to the category#

    Ah, excellent to hear you got this configured correctly! Thanks for confirming as much, Steve. Let us know if we can do anything else down the road.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Custom Loop for The Events Calendar’ is closed to new replies.