Show All Events

How can I make the event page show all events ever posted versus only future events?”

We will give you a solution which will order all events (both upcoming and past) by start date in descending order.

Please follow these instructions:

0. make sure to backup file we are about to change
1. open page-events.php
2. find these lines:

	$args['post_type'] = 'event';
	$args['post_status'] = 'publish';
	$args['posts_per_page'] = 10;
	$args['order'] = 'ASC';
	$args['orderby'] = 'meta_value';
	$args['meta_key'] = '_start_date';
	$args['meta_query'] = array(
		array(
			'key'		=> '_start_date',
			'value'		=> $today,
			'compare'	=> '>'
		)
	);

and change them to read:

	$args['post_type'] = 'event';
	$args['post_status'] = 'publish';
	$args['posts_per_page'] = 10;
	$args['order'] = 'DESC';
	$args['orderby'] = 'meta_value';
	$args['meta_key'] = '_start_date';

 

0