• Author
  • #1117994


    Is it possible to have subcategories under my main link category? In my case I’ve got Recipes in right hand bar and want to add sub links to Vegetarian, Baking, Fish etc… Is it because I have a one menu template that I can’t seem to do it please? Also, on my Recipes page I would like something similar – main headings eg. Vegetarian, Baking and relevant recipes listed underneath. Thanks for your help.

    The blog I need help with is



    Hi there – you can indeed make sub-categories, by assigning a “Parent” category to the sub-category. You’d can do that under Posts > Categories:

    When you add the new sub-category, just assign it a parent by choosing an existing category from the drop-down menu under “Parent.”

    In terms of your Recipes page, you could try experimenting with this shortcode:


    You could adapt it as needed to display your categories and sub-categories in whatever order you like.

    Here’s a guide to using that shortcode:

    So for example, if you wanted to include a list of your Dessert posts, you would add the shortcode to your page:

    [display-posts category="desserts"]

    The bit next to the word “category” needs to match your category “slug” – defined here in the “slug” column.

    If you need further help, just let me know.



    Hi Kathyrn. Thanks for the information and I’ve managed to create a list of recipes under categories on the recipes page using the display-posts shortcode.

    I want to also put a thumbnail image from each recipe next to each link. I tried putting [display-posts image_size="thumbnail"] underneath first bit of code but it just seems to add a list of more recipes and no image. Is is possible to do what I’m asking please? Thanks.



    Hi there, have you tried a single shortcode per category that looks like this for the vegetarian category, for example?

    [display-posts category="vegetarian" image_size="thumbnail"]

    Let me know if this works.

    I also noticed you have some extraneous links on your shortcodes. They don’t seem to be doing any harm, but for cleaner code, you can remove them. Just click a shortcode that has a link on it and then click the “unlink” button.



    Hi again. Tried the single shortcode as you suggested but it unfortunately doesn’t do anything – no sign of any images.
    Where is the unlink button please? Thank you.



    I’m sorry that didn’t work. You may need to add a thumbnail manually, in that case.

    The unlink button is just next to the link button:

    Add New Post ‹ Test Site — WordPress.jpg



    Hi again. I’ve manually inserted thumbnail photos but I want to put the category list into a specific order to match the same order of photos. I’ve tried listing them using their title, as per below, but all I get is a jumbled up random list and throws everything out. Any ideas please? Thanks.

    [display-posts -"tomato couscous thumbnail","flatbreads with hummus thumbnail"]



    By default, the posts display in reverse chronological order, from the most recent to the oldest. You can reverse that to show the oldest first, by adding order=”ASC” – as you see here:

    Specify whether posts are ordered in descending order (DESC) or ascending order (ASC).
    Default: DESC
    Example: [display-posts order="ASC"]

    If you want the thumbnail order to match the order in which posts are listed, it would be easier to change the order of your thumbnails to match the order of posts.

The topic ‘Subcategories’ is closed to new replies.