• I had seen when the development had made this change:
    (https://mosquito.www.ads-software.com/view.php?id=1252)

    “next_post() and previous_post() are deprecated in favor of next_post_link() and previous_post_link()”

    These new tags are used in the updated default template, but the codex does not yet have this documented.

    Before I upgrade, I would like to check if next_post_link() and previous_post_link() actually do work in limiting to the current category, + also are there any configurable parameters (they show '«??%link' -and- '%link??»'). I especially want to configure the string to read a generic “Next Entry” rather than the post title.

    Can anyone report how these are working to constrain to same category + how they appear. Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • I also noticed next_post_link is not in the Codex that I can find. Is there any more info posted about it? I’m new at modifying my template, but finally getting down to wanting to change the Post template. These tags are used in the Default Template based on Kubrick.

    I have the same question as previous post — how to display generic “NEXT POST” instead of post-titles.

    EDIT: I will probably find answers in other threads I’m finding via search like https://www.ads-software.com/support/topic/34939

    Codex still hasn’t documented these functions, and previous_post/next_post are still in there with no suggestion that they’re deprecated.

    So can I take it that developers have changed their minds on this and I’m OK to use previous_post instead? Or would I be better off delving into the functions file to find which parameters are taken by previous_post_link?

    (I suppose I should do the latter anyway and document my findings on Codex for the benefit of the community, but theme competition deadline is in a week’s time so I’d prefer to minimise the detective work right now.)

    They (next/previous_post) are still marked as deprecated, so it’d be smarter to go with the next/previous_post_link tags (both in the current release pass off to get_next/previous_post() to get the link in any case, as they are the behind the scenes workhorse for this now).

    I’m not sure how these got missed in the last big hit on the template tags done on Codex, but I’ll mark them on my todo list (should probably revisit all the tag docs…yeah boy…).

    Will do, thanks for the quick reply!

    You can have a look here and get all information you need
    https://www.redalt.com/fn/1678
    You have to write this to display [Previous Post:URL]:
    previous_post_link('« %link', 'Previous post')
    I hope it could help you.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘next_post_link() previous_post_link()’ is closed to new replies.