Reorder Custom Post Type Post Navigation
-
You can see the development site here: new.wearelfb.com
I am currently using your plugin to reorder the full list of Custom Post Types on my homepage and it works great.
However, I want to use the same order once inside a Post to change the Post Navigation order so it matches the order of the homepage. See a post example here: https://new.wearelfb.com/work/main-street-dental/
I’m currently using a slightly altered TwentyThirteen function for the Post Nav:
if ( ! function_exists( 'twentythirteen_post_nav' ) ) : /** * Displays navigation to next/previous post when applicable. * * @since Twenty Thirteen 1.0 * * @return void */ function twentythirteen_post_nav() { global $post; // Don't print empty markup if there's nowhere to navigate. $previous = ( is_attachment() ) ? get_post( $post->post_parent ) : get_adjacent_post( false, '', true ); $next = get_adjacent_post( false, '', false ); if ( ! $next && ! $previous ) return; ?> <nav class="navigation post-navigation" role="navigation"> <div class="nav-links"> <?php previous_post_link( '%link', _x( '<span class="meta-nav">?</span><span class="nav-title prev">%title</span>', 'Previous post link', 'twentythirteen' ) ); ?> <?php next_post_link( '%link', _x( '<span class="nav-title next">%title</span><span class="meta-nav">?</span>', 'Next post link', 'twentythirteen' ) ); ?> </div><!-- .nav-links --> </nav><!-- .navigation --> <?php } endif;
I have tried to implement the same loop array that I used to reorder the homepage list, but I cannot get this to work for the Post Navigation order.
Is there a simple edit to the Post Navigation function that will gather the Reorder of the custom post types instead of the ID order?
Thanks in advance for any help towards this issue!
- The topic ‘Reorder Custom Post Type Post Navigation’ is closed to new replies.