How to Remove Categories from Header?

Discussion in 'WordPress' started by Snipers, Jul 5, 2011.

  1. #1
    Hi,
    I installed 2 themes but both have categories in the header and I have lot's of categories so I want to remove Categories.
    I will use category as a widget in the sidebar.
    Have you any ideas on how to remove categories from header area?

    Thanks for your help.
     
    Snipers, Jul 5, 2011 IP
  2. karoshio

    karoshio Active Member

    Messages:
    143
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    65
    #2
    I'm guessing you mean the navigation bar piece that some themes have, if so you could just remove the bar through the template editor? I'm unsure if there is a way through wordpress settings but if you go the navigation or header or whatever it may be called template then it shouldn't take much to find and remove it.
     
    karoshio, Jul 5, 2011 IP
  3. MTbiker

    MTbiker Well-Known Member

    Messages:
    2,536
    Likes Received:
    123
    Best Answers:
    0
    Trophy Points:
    170
    #3
    MTbiker, Jul 5, 2011 IP
  4. bob25

    bob25 Well-Known Member

    Messages:
    1,519
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    128
    #4
    bob25, Jul 5, 2011 IP
  5. Snipers

    Snipers Peon

    Messages:
    236
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #5
    thanks for your reply, however i tried to edit header.php but not succeed.i have lot's of templates which will need editing.
    for better understanding i have added a screenshot of a demo theme http://imageshack.us/f/194/unledbef.png/ , please check once and advise how to remove categories.

    thanks
     
    Last edited: Jul 5, 2011
    Snipers, Jul 5, 2011 IP
  6. MTbiker

    MTbiker Well-Known Member

    Messages:
    2,536
    Likes Received:
    123
    Best Answers:
    0
    Trophy Points:
    170
    #6
    Just to clarify - do you want to exclude categories from the list, or do you want to completely eliminate having the categories listed across the top?

    There are plugins like bob25 mentioned, and some themes have that functionality built in, but I usually edit files manually. Here's a code example using the "exclude" I was talking about (it's for pages, but it's the same concept):

    <?php wp_list_pages('sort_column=menu_order&depth=0&exclude=3,9,11,12,13,14,34,37,53&title_li='); ?>
    PHP:
    Here are some links for more info:
    http://codex.wordpress.org/Template_Tags/wp_list_categories
    http://faq.wordpress.net/view.php?p=56
    http://wpgarage.com/plugins/exclude-categories-from-feed-archives-search-and-home-page-in-wordpress/
     
    MTbiker, Jul 6, 2011 IP
  7. waziuz

    waziuz Active Member

    Messages:
    783
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    80
    #7
    There are a few ways to do it.

    http://codex.wordpress.org/Function_Reference/query_posts#Exclude_Categories_From_Your_Home_Page

    Best way exclude using the code.

    Second way is to remove the default categories in the navigation menu and only add a list of categories you want to use.

    Last way which I use a lot is to remove the categories list completely and instead use an adsense link ad in case I am using adsense on that blog. Works out well. ;) Also removes the headache of selecting the categories to use on the header out of the all the categories already present in the sidebar.
     
    waziuz, Jul 6, 2011 IP