Support » Fixing WordPress » Exclude categories in homepage

  • Aen

    (@aen)


    How do I exclude certain categories in the homepage? Right now it’s display entries of every category, I wish to exclude some.

Viewing 6 replies - 1 through 6 (of 6 total)
  • BPartch

    (@bpartch)

    Hello

    You will need to edit the sidebar.php file

    <?php wp_list_cats('sort_column=name&exclude=1, 2, 3, 4'); ?>

    The 1, 2, 3, 4 are the category ID numbers that will be excluded in the example above.

    moshu

    (@moshu)

    BPartch

    (@bpartch)

    O, haha, I think I misunderstood what you we’re asking. Sorry about that.

    clarissa

    (@clarissa)

    To BPartch – I wanted to do exactly that – exclude some categories from my sidebar. However, when I included your code above, my categories displayed “None”. Do you think you can help? Thanks!

    moshu

    (@moshu)

    Replace the 1, 2, 3, 4 with the ID# numbers of your own categories that you want to exclude.

    clarissa

    (@clarissa)

    I already did that, but the result is still “No categories”.

    And I apologize for asking this question twice. The other topic with my complete coding: http://wordpress.org/support/topic/79855

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Exclude categories in homepage’ is closed to new replies.