Forums

wp_redirect to page number of a specific post? (2 posts)

  1. kg
    Member
    Posted 1 year ago #

    $pageNumberContainingPostId = ???

    wp_redirect( get_bloginfo('url')
    . '/page/'
    . $pageNumberContainingPostId );

    Is this possible?

    In english, to be able to redirect wordpress to a page that contains say post_ID=50

    Thanks in advance

  2. Mark / t31os
    Moderator
    Posted 1 year ago #

    The page a blog post is on changes as the number of posts does, so in short, no it wouldn't be possible, since the page number is not static.

Topic Closed

This topic has been closed to new replies.

About this Topic