[resolved] Can a template be set up for a "Posts Page"? (5 posts)

  1. Anonymous
    Posted 6 years ago #

    Is it possible to set up a template for a page to display posts, which isn't the frontpage?

    I have set up my site in settings > reading as such:

    Front page displays > A static page > Front page:Home > Posts page:News

    "Home" has a template of "myhome.php" defined, which displays fine on the homepage. "News" has a template of "mynews.php" defined, but this isn't picked up.

    Can a template be used for an alternative post page?


  2. Anonymous
    Posted 6 years ago #

    is the answer - i don't need to because index.php / single.php and archive.php will handle all appearance of the "News" posts anyway, so there is no need for a separate template?

  3. Essentially, yes. The "blog" page uses the index.php file. You can't assign it a Page Template because when it is processed, it is not a "Page" even though you've assigned it to be on a page. Basically, that static page thing gives the main posts page a different URL, but not a different place in the template hierarchy.

  4. Anonymous
    Posted 6 years ago #

    Thanks Otto - that's cleared that up then.

  5. ggwarpig
    Posted 6 years ago #

    This is a little buggy, because if Anonymous were to go edit his "News" page, WP lets him select his "mynews.php" template.

Topic Closed

This topic has been closed to new replies.

About this Topic