Support » Fixing WordPress » posts not showing- static homepage, different post page template

  • Resolved alexisfrsh

    (@alexisfrsh)


    Live site.

    I’ve got a custom theme, wherein the homepage(home.php) is static and the “posts” page is Press(index.php). Everything with the theme works great, with the exception of the posts not showing when viewing the Press page- it shows the homepage content instead.

    In the Reading settings, I have A Static Page: Front Page is Home / Posts Page is Press.

    Here’s what I’m using for index.php:

    pastebin

    Any ideas what could be causing the issue? I’m sure it’s something simple, I’ve just been working on this for so long I need fresh eyes. Thanks.

Viewing 15 replies - 1 through 15 (of 15 total)
  • esmi

    (@esmi)

    Forum Moderator

    Change home.php to front-page.php and then use Settings -> Reading to set up a static home & main posts page.

    Thanks for your quick response.
    After your suggestion, my settings are:

    Front page displays: static page.
    Front page: HOME
    Posts page: PRESS

    Also, I’ve changed home.php to front-page.php and left index.php the same.

    Despite this, the problem persists.

    esmi

    (@esmi)

    Forum Moderator

    Sorry – change front-page.php to frontpage.php

    Changed, still no luck.

    I don’t know if this will help troubleshooting purposes, but I’ve also tried creating an index.php copy file/template called press.php and using that as the Press page template. That change made no difference.

    esmi

    (@esmi)

    Forum Moderator

    That will never work. The main posts page uses index.php by default. Have you tried:

    – deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    – switching to the Twenty Eleven theme to rule out any theme-specific problems.

    resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems.

    Thanks again for your help!
    Switching to the Twenty Eleven theme allowed for the Press page to work properly, which I guess means my issue is theme specific.
    How should I go about pinpointing the cause of all of this?

    esmi

    (@esmi)

    Forum Moderator

    Where did you download the theme from?

    Oh, it’s custom; I made it.

    esmi

    (@esmi)

    Forum Moderator

    In that case, all I can say is that there’s an issue in your theme. 🙁

    Haha, that does seem to be the case.
    Thanks for your help!

    Michael

    (@alchymyth)

    Forum Moderator

    what is the code of header.php?

    Also, for what it’s worth, I’ve just noticed that style.css doesn’t seem to be working in Safari. This didn’t happen until I added the Press page and subsequent changes.

    Turns out, the initial WP install was faulty which caused a bunch of little things to go awry.

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘posts not showing- static homepage, different post page template’ is closed to new replies.