WordPress.org

Forums

Show Uncategorized Title and Description (1 post)

  1. StyledThemes
    Member
    Posted 1 year ago #

    Unless I missed it somewhere, how does one get the (formerly Uncategorized category which is renamed) title and description to show up at the top of the home blog page when using a static front page with blog?

    I noticed that when you drag the new home and blog pages to the main menu, the blog is your new home page but it does not display the title or description. But, if you have the category widget published and click on the home blog category (formerly the uncategorized one), then the title and description show.

    I tried this but it doesn't want to work unless you go to the other categories or click on the category widget link that links to the default blog category (uncategorized) :

    <h1 class="category-title"><?php single_cat_title('Currently browsing '); ?></h1>
    <?php if ( category_description() ) : // Show an optional category description ?>
    <div class="category-description"><?php echo category_description(); ?></div>
    <?php endif; ?>

Topic Closed

This topic has been closed to new replies.

About this Topic