Tagged: pagination
- This topic has 4 replies, 2 voices, and was last updated 8 years, 7 months ago by Theme Horse Support Team.
-
AuthorPosts
-
August 27, 2015 at 8:36 pm #27761beth_almeidaParticipant
I’m trying to customize the order of pages that my previous and next buttons cycle through, and right now it’s using all pages that I’ve created. I can’t find the php file where I can customize the order or to only grab a category — has anyone found this? Help is appreciated!
August 28, 2015 at 6:34 am #27769Theme Horse Support TeamKeymasterHi analytic_header,
First of all we recommended you not to customize the code. If you customize the code then while udpating to our new version all your customized code will be lost. So you need to create a child theme and then customize the code.
The previous and next buttons cycle is from theme folder ambition -> inc -> structure -> content-extension.php on line no 417 you will find this function code
add_action( 'ambition_after_loop_content', 'ambition_next_previous', 5 ); /** * Shows the next or previous posts */ function ambition_next_previous() { if( is_archive() || is_home() || is_search() ) { /** * Checking WP-PageNaviplugin exist */ if ( function_exists('wp_pagenavi' ) ) : wp_pagenavi(); else: global $wp_query; if ( $wp_query->max_num_pages > 1 ) : ?> <ul class="default-wp-page clearfix"> <li class="previous"> <?php next_posts_link( __( '« Previous', 'ambition' ) ); ?> </li> <li class="next"> <?php previous_posts_link( __( 'Next »', 'ambition' ) ); ?> </li> </ul> <?php endif; endif; } }
Thank you!
September 8, 2015 at 7:45 pm #28074beth_almeidaParticipantThanks so much for your help!
September 8, 2015 at 8:10 pm #28075beth_almeidaParticipantI was hoping to change the pagination to only pages under a certain category so that it is not including all my pages — is this possible?
September 10, 2015 at 8:34 am #28116Theme Horse Support TeamKeymasterHi beth_almeida,
This is not possible in our theme. It needs code customization and you need to hire a developer to fix it.
Thank you!
-
AuthorPosts
- You must be logged in to reply to this topic.