Twenty Fifteen: Adjacent posts by menu_order
I'm using the Twenty Fifteen (child) Theme and want to display the previous / next post links with the background image for my hierarchical custom post type.
It is being displayed, unfortunately the order seems completely wrong. I assume this is because the post are being selected by date and not by menu order?
I want the next / previous post to be like I have ordered them in the backend menu, and it should be shown regardless of if its a parent, child or sibling to the current post.
The code for this is in the single.php:
the_post_navigation( array(
'next_text' = 'span class="meta-nav" aria-hidden="true"' . __( 'Next', 'twentyfifteen' ) . '/span ' .
'span class="screen-reader-text"' . __( 'Next post:', 'twentyfifteen' ) . '/span ' .
'span class="post-title"%title/span',
'prev_text' = 'span class="meta-nav" aria-hidden="true"' . __( 'Previous', 'twentyfifteen' ) . '/span ' .
'span class="screen-reader-text"' . __( 'Previous post:', 'twentyfifteen' ) . '/span ' .
'span class="post-title"%title/span',
) );
How can I get the posts in the correct order?
Topic theme-twenty-fifteen navigation hierarchical custom-post-types Wordpress
Category Web