[resolved] Exclude category from the menu! (3 posts)

  1. MrDanielson
    Posted 5 years ago #

    Hey people!

    I downloaded the template ThrillingTheme, and in the menu there is listed the categories.

    I've tried to do a "&limit=7" in the menu code, but it didnt change anything - it's still all categories showing.

    After that I've tried exclude&7 (category ID 7), but it just didnt exclude it.

    What did I do wrong?

    Help me please. :-)

    The code:

    <ul id="nav" class="grid_15">
    			<?php include(TEMPLATEPATH . '/includes/version.php'); ?>
    			<?php wp_list_categories('title_li=&exclude=7&orderby=count&order=DESC&limit=7') ?>
  2. Michael
    Part-Time Forum Moderator
    Posted 5 years ago #

    there is no parameter 'limit' - the parameter to set the number of categories shown is 'number'

    (integer) Sets the number of Categories to display. This causes the SQL LIMIT value to be defined. Default to no LIMIT.

    there is a possibility that the wrong parameter disturbed the other parameters as well;

    try again with this code:

    <?php wp_list_categories('title_li=&exclude=7&orderby=count&order=DESC&number=7') ?>
  3. MrDanielson
    Posted 5 years ago #

    Thanks for the help dude! :)

Topic Closed

This topic has been closed to new replies.

About this Topic