[resolved] Functions previous_post_link() and next_post_link() do not work (3 posts)

  1. John Peden
    Posted 3 years ago #

    I'm trying to load a post navigation function above my post title and after my post comments in Genesis. Here is the function that I'm running:

    /** Load previous/next post link before title */
    function genesis_post_navigation() {
    	if ( is_single ( ) ) {
    		echo '<div class="prev-next-posts"><div class="prev-post-link">';
    		echo '</div><div class="next-post-link">';
    		echo '</div></div>';
    add_action( 'genesis_before_post_title', 'genesis_post_navigation');
    add_action('genesis_after_comments', 'genesis_post_navigation');

    Everything works as it should aside from the links generated by the WP functions: previous_post_link() and next_post_link(). The only post previous links to is 'Hello World' i.e. the oldest post on the blog and the only post next links to is the second-oldest. Most of the time, the links don't actually display anything at all.

    You can see the site in action here.

    What is going on here and why doesn't it work properly?

  2. We don't support the Genesis framework here as that's a commercial product and we do not have access to that code.

    But cheer up, I've reason to believe that the support there is very good. Why not head over to their forums and ask there?


    Part of what you paid for was support and you may as well take advantage of that option.

  3. John Peden
    Posted 3 years ago #

    Ok thanks for the suggestion. I'll ask on Studiopress.

Topic Closed

This topic has been closed to new replies.

About this Topic