Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $citywideEvents = wp_get_post_terms( $post->ID, 'citywide' );
- $cityevents = new WP_Query(
- array(
- 'posts_per_page' => 4,
- 'post_type' => 'events',
- 'events_type' => $eventsTerms,
- 'category' => array( $post->ID )
- )
- ); ?>
- <?php if ( $cityevents->have_posts() ) : ?>
- <?php while ($cityevents->have_posts()) : $cityevents->the_post(); ?>
- <?php
- $events = tribe_get_events( array(
- 'posts_per_page' => 5,
- 'start_date' => new DateTime()
- ) );
- foreach ( $cityevents as $post ) {
- setup_postdata( $post );
- // This time, let's throw in an event-specific
- // template tag to show the date after the title!
- the_title();
- echo tribe_get_start_date();
- the_content();
- }
- ?>
- <?php endwhile; ?>
- <?php wp_reset_postdata(); ?>
Advertisement
Add Comment
Please, Sign In to add comment