Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Sergio De Falco

    (@sgr33n)

    Hi,

    The continue link is for quickly read the entire post, so you don’t need to read what you have already read. The previous page link is on the table of contents.

    Anyway I can add an option to keep the original pagination instead of the continue link.

    Thread Starter NaturesLens

    (@natureslens)

    Cool – yeah I see what you mean – I am using it to split long pages into sections – so people might want to go back to the previous section in my case

    If it is still in your interest, I’ve came up with a quite easy solution.
    Perhaps this can be an option in a new release?

    For now: You have to change the following if claue in sgr-nextpage-titles.php

    if ( $page === max( array_map( 'count', $subpages ) ) ) {
    			$multipagenav = '<div class="multipage-navlink">' . __( 'Back to: ', 'sgr-npt' ) . ' <a href="' . get_permalink() . '">' . $subpages['title'][ 0 ] . '</a></div>';
    		} else {
    			$multipagenav = '<div class="multipage-navlink">' . __( 'Continue:', 'sgr-npt' ) . ' <a href="' . $this->get_subpage_link( $page +1 ) . '">' . $subpages['title'][ $page ] .'</a></div>';
    		}

    with

    if ( $page === max( array_map( 'count', $subpages ) ) ) {
    			//prev and first
    			$multipagenav = '<hr/><div class="multipage-navlink" style="text-align: left; float: left;">' . __( 'Previous:', 'sgr-npt' ) . ' <a href="' . $this->get_subpage_link( $page -1) . '">' . $subpages['title'][ $page -2 ] . '</a></div>
    					 <div class="multipage-navlink">' . __( 'Back to: ', 'sgr-npt' ) . ' <a href="' . get_permalink() . '">' . $subpages['title'][ 0 ] . '</a></div>';
    		} else if ( $page != 1 ) {
    			//prev and next
    			$multipagenav = '<hr><div class="multipage-navlink" style="text-align: left; float: left;">' . __( 'Previous:', 'sgr-npt' ) . ' <a href="' . $this->get_subpage_link( $page -1) . '">
    ' . $subpages['title'][ $page -2 ] . '</a></div>
    					 <div class="multipage-navlink">' . __( 'Next:', 'sgr-npt' ) . ' <a href="' . $this->get_subpage_link( $page +1 ) . '">' . $subpages['title'][ $page ] .'</a></div>';
    		} else {
    			// next
    			$multipagenav = '<hr></hr><div class="multipage-navlink">' . __( 'Next:', 'sgr-npt' ) . ' <a href="' . $this->get_subpage_link( $page +1 ) . '">' . $subpages['title'][ $page ] .'</a></div>';
    		}

    Perhaps some others find this useful, too.

    Plugin Author Sergio De Falco

    (@sgr33n)

    Hi,

    It’s not an option for now, I don’t think it’s really needed a previous link when you already have that link in the table of contents.

    The continue link is just for quickly read the entire post (infact it’s “continue” not “next”), not to navigate through subpages, for that you already have the table of contents.

    MimmiN

    (@mimmin)

    I would like this option, but I also see your argument Sergio.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Previous Page Link as well as the next page link’ is closed to new replies.