• I found the following in the twentyseventeen default theme, out of the box version of the front-page.php file, starting on line 25:

    else : // I’m not sure it’s possible to have no posts when this page is shown, but WTH.
    get_template_part( ‘template-parts/post/content’, ‘none’ );

    The answer is, NO, it is NOT possible because if there are no pages or posts in your WordPress instance, index.php is loaded.

    It is therefore unnecessary to provide this fallback logic on front-page.php

    • This topic was modified 7 years, 8 months ago by troycono.
    • This topic was modified 7 years, 8 months ago by troycono.
    • This topic was modified 7 years, 8 months ago by troycono.
  • The topic ‘front-page.php logic question – ANSWERED’ is closed to new replies.