• Hello –

    Am working on updating from 2.3.3 to 2.6.1 — I noticed that the functionality of next_post_link() seems to have changed ….

    If I use this code in 2.3.3:

    <?php next_post_link('%link','Next Blog Post &raquo;',TRUE,'2') ?>
    <?php next_post_link('%link','Next Event &raquo;',TRUE,'1') ?>

    It would generate either one link or the other (depending on the category I was in). In 2.6.1, however, it generates TWO links (seeming to ignore the “exclude” specification).

    I have tested adding this code to an unfettered “default” theme under both 2.3.3 and 2.6.1 and in the former it works as expected, in the latter, it is broken. I check the codex but no mention of it being removed …

    Anyone able to get this to work on 2.6.1 ? Is it just me ?

    Thanks,
    Damon

Viewing 2 replies - 1 through 2 (of 2 total)
  • If you can’t get it working, you could always use the in_category conditional tag and php if else to display one or the other next_post_link depending on the post’s category.

    Thread Starter thornomad

    (@thornomad)

    Thank you for that suggestion – I was going to head somewhere in that direction if, indeed, next_post_link was no longer working as intended.

    I just wondered if anyone else was experiencing this problem or if it was something on my end … I thought I had been doing it right (according to the codex) and was curious if it was me or the new version.

    Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Did next_post_link break in 2.6 ?’ is closed to new replies.