WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: Number My Post Pages] Cannot Get it to work (7 posts)

  1. mack28
    Member
    Posted 4 years ago #

    I am trying to place <?php mysinglepages(wp_link_pages(array('before' => '', 'after' => '', 'next_or_number' => 'number','echo' => '0'))); ?> on my index page and single.php page. Where exactly should it be placed?

    Nothing seems to work!

    Here is what is there now:
    Index Page:

    <div class="navi">
    <div class="left"><?php next_posts_link('&laquo; Previous Entries'); ?></div>
    <div class="right"><?php previous_posts_link('Next Entries &raquo;'); ?></div>
          </div><!-- end navi -->

    Single.php:

    <div class="navi">
    <div class="left"><?php previous_post_link('&laquo; %link') ?></div>
    <div class="right"><?php next_post_link('%link  &raquo;') ?></div>
    <div style="clear:both;"></div>
    </div><!-- end navi -->

    Thanks in advance for your support.

    http://wordpress.org/extend/plugins/number-my-post-pages-plugin/

  2. asipahio
    Member
    Posted 4 years ago #

    I guess I should write a more detailed explanation.

    You need to replace the

    <? wp_link_pages(array('before' => '', 'after' => '', 'next_or_number' => 'number','echo' => '0'))?>

    with

    <?php mysinglepages(wp_link_pages(array('before' => '', 'after' => '', 'next_or_number' => 'number','echo' => '0'))); ?>

    If you don't have that then just inside your "loop" place the function call;

    <?php mysinglepages(wp_link_pages(array('before' => '', 'after' => '', 'next_or_number' => 'number','echo' => '0'))); ?>

    -------------
    The lines you put are for a different purpose. Those are to go to the next and previous post not to paginate inside a post. Hope that explains it a bit more, I am really not good at explaining things :)

  3. banciii
    Member
    Posted 4 years ago #

    hi! i installed succesfully this plugin, but it doesnt work for me. it apperars at the bottom of the page, but it shows only the page 1 and i cant klick on the next or on the prevously bottom :S (i have already tried to change the number of the shown posts at the WP options, but still nothing... i cant see the older posts before page 1 :S)

  4. asipahio
    Member
    Posted 4 years ago #

    Do you use permalinks? and whats their structure?

  5. dag_henning
    Member
    Posted 4 years ago #

    Hi, im having a simliar problem.

    Im using the plugin on my single.php template file. (in a custom theme)
    The links (number & pages) work fine when i click beyond page 2.
    If i attempt to click next page, or page 2, from the first page, nothing happens,
    or it loads the first page again.

    This is driving me nuts. Also the navigation for the built in wp_link_pages doesnt work with next/previous. only numbers.

    I use: /%category%/%postname%/ as my permalink structure.

    Any help would be much appreciated.

  6. asipahio
    Member
    Posted 4 years ago #

    what does the link look like on number 2?

    What version of wp are you using by the way?

  7. asipahio
    Member
    Posted 4 years ago #

    Sorry for the late response, I mostly answer questions on the plugin homepage not here.

Topic Closed

This topic has been closed to new replies.

About this Topic