Custom Date range.
-
My client insist that each event be posted by month, However I don’t think I understand how the custom date range works. As this is supposed to pull event only for January, yet I get feb dates.
<?php global $post; $current_date = date('1-01-2013'); $end_date = date('1-31-2013'); $get_posts = tribe_get_events(array('start_date'=>$current_date,'end_date'=>$end_date,'posts_per_page'=>10) ); foreach($get_posts as $post) { setup_postdata($post); ?> <div class="rg-events-loop"> <div class="rg-events-date"><?php echo tribe_get_start_date($post->ID, false, 'F j, Y'); ?></div> <div class="rg-events-title"><h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2></div> </div> <div class="rg-events-meta-list"> <ul> <?php if( tribe_address_exists( get_the_ID() ) ) {echo '<li>' . tribe_get_full_address( get_the_ID() ) .'</li>';} ?> <?php if($cfs->get('host')){echo '<li>' . $cfs->get('host') . '</li>';}?> <?php if($cfs->get('event_url')){echo '<li><a href="' . $cfs->get('event_url') .'">'. $cfs->get('event_url') .'</a></li>';}?> </ul> </div> <?php } //endforeach ?> <?php wp_reset_query(); ?>
https://www.ads-software.com/extend/plugins/the-events-calendar/
Viewing 13 replies - 1 through 13 (of 13 total)
Viewing 13 replies - 1 through 13 (of 13 total)
- The topic ‘Custom Date range.’ is closed to new replies.