Hide categories from main page

  • Unknown's avatar

    Hi Guys,

    I’m looking to hide a specific category from my wordpress.com blog homepage, i have created a new category called ‘Reviews’ which i want to appear via a menu but not on my posts page. i am trying to use either CSS or short codes to achieve this but i’m struggling to find the right place or order of making the changes.

    I believe i need to use a short code like the below which doesn’t include the category of reviews in order to omit that specific category:

    [display-posts category="Adventure, Creative, HDR, Long Exposure, Music, Night, Sports, Travel, Tutorial, Uncategorized, Urban"]

    Can someone let me know how i can implement this?

    Thanks in advance for the help.

    Neil.

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    This isn’t really possible with the standard blog page on Baskerville because each post location is calculated by the theme software, so if we exclude a certain category from the main page – which we can – there will be holes in the main page where those posts would be. The posts will not reflow to give a full grid.

    Your best bet, if this is what you are wanting would be to use the Display Posts shortcode. You would put the code into a page and then set that page as your static Front Page. The layout and formatting is not going to be what you see now on your main page, it will be a single column and it is problematic to make it into multiple columns. It looks like you have already seen this, but I’ll include a link to the Display Posts Shortcode support page for reference.

  • Unknown's avatar

    Thanks thesacredpath for replying,

    Is there a place where i can view the features or differences between the themes? Or are they pretty similar? Hoping there might be a theme that’s more suited to the style of blog that i want.

    I think i might try and create a hierarchy of pages to achieve my goal of having a ‘second post page’ I can then use a static page to link to other pages or have them drop down from a menu, just not sure if static pages return in searches like post pages would from a standard search engine..

    thanks for all your help and advice!

  • Unknown's avatar

    Most of the themes that have a grid style of layout on the Front Page Template page have the locations set in the theme itself and if you hide a certain category, it creates holes where those posts were.

    On standard blog layouts (single column listing of posts), you can hide certain categories, or even all but a single category of posts on the blog page using CSS.

    Give your idea a try and see how that works for you and let me know if you have any questions.

  • Unknown's avatar

    thanks for replying again, I’ve found a ugh the workaround which seems to suit my theme, not sure if it will have any impact on the site from a search engine point of view.

    I created categories and added them to the menu, I then bulk added the category ‘blog’ to all my posts that I wanted to appear on my new ‘post page’ which is actually just a category for blog, I’ve then created a new category called ‘gear reviews’ and added this to the menu, I’ve changed my site to a static home page and then not selected any page as my post page.

    I feel like this gives the impression that I have two post pages one for ‘blog’ and one for ‘gear reviews’ whilst keeping my true post page hidden.

    Fingers crossed hiding the post page doesn’t affect my site from a search engine stance, I’m pretty happy with the way it looks now so thanks for your guidance!

    Neil

  • Unknown's avatar

    Neil, I see absolutely nothing wrong with the way you have done this. Good thinking!

  • The topic ‘Hide categories from main page’ is closed to new replies.