Cant seem to edit posts.
Anyway, it looks like its more than just adding a standard meta key parameters to the query.
How would i adjust the query to sort by event date? Below is my code. Note the count is used for displaying the events in a 2 column grid layout:
<?php
$query = new WP_Query( 'posts_per_page=6&post_type=espresso_events' );
$count = 0;
if ( $query->have_posts() ) : while ( $query->have_posts() ) : $query->the_post();$count++;
if ($count%2== 0) :
?>
Perfect, that did exactly what I required. Many thanks
Viewing 3 reply threads
The support post ‘WP Query + Ordering events by their date’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.
Support forum for Event Espresso 3 and Event Espresso 4.