Skip to content

Instantly share code, notes, and snippets.

@Pebblo
Created April 15, 2021 11:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Pebblo/15ed8256b55409a0f43215045712f112 to your computer and use it in GitHub Desktop.
Save Pebblo/15ed8256b55409a0f43215045712f112 to your computer and use it in GitHub Desktop.
<?php //PLease do not include this opening PHP tag if you already have one.
function tw_ee_add_pagination_to_ee_events( $wp_query ) {
if( is_post_type_archive('espresso_events') ) {
// Previous/next page navigation.
the_posts_pagination( array(
'prev_text' => '<i class="fa fa-angle-double-left"></i>',
'next_text' => '<i class="fa fa-angle-double-right"></i>',
) );
}
}
add_action('loop_end', 'tw_ee_add_pagination_to_ee_events');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment