首页 > 解决方案 > Wordpress Archive page completely blank

问题描述

I have the following archive page setup:

<?php

get_header(); ?>

<div id="container">
    <div id="content" role="main">

        <?php the_post(); ?>
        <h1 class="entry-title"><?php the_title(); ?></h1>

        <?php get_search_form(); ?>

        <h2>Archives by Month:</h2>
        <ul>
            <?php wp_get_archives('type=monthly'); ?>
        </ul>

        <h2>Archives by Subject:</h2>
        <ul>
             <?php wp_list_categories(); ?>
        </ul>

    </div><!-- #content -->
</div><!-- #container -->

<?php get_sidebar(); ?>
<?php get_footer(); ?>

However, the page is completely white when I load the archive page. It is a new site with no plugins, and all the other pages are working fine. Any idea?

标签: phpwordpresswordpress-theming

解决方案


出于某种奇怪的原因,当我将代码添加到 index.php 文件时,存档变得可见。


推荐阅读