• Resolved zomzommarketing

    (@zomzommarketing)


    Hi,
    I am using a theme that is compatible to 2.0.1 with WordPress 2.1. Is this why any change I make to the wp_list_cats doesn’t do a darn thing or is there some other problem I should be aware of?

    Even the simplest of changes like sort by name or id results in nothing but the default.

    If this is the reason then can someone kindly point me to a tutorial on upgrading the theme. My search results only point to upgrading the WordPress version.

    I thought I would post here before downgrading my install back to 2.0.1

    Thanks in advance.

Viewing 12 replies - 1 through 12 (of 12 total)
  • Try the template tag, wp_list_categories, instead of wp_list_cats.

    Thread Starter zomzommarketing

    (@zomzommarketing)

    I have tried that before posting this but thanks for that quick reply. That’s why I’m thinking I need to replace more elsewhere in the theme than just the one line.

    So you say it (using wp_list_categories) doesn’t do anything…

    Where are you placing the code, in your sidebar.php file?

    What theme are you using?

    Exactly what code are you using for wp_list_categories?

    Thread Starter zomzommarketing

    (@zomzommarketing)

    The code is in my sidebar.php file.

    It looks like this:
    <?php wp_list_categories('orderby=id&exclude=4'); ?>

    But it still orders by name and category 4 still is on display.

    (I made a home page with <?php get_header(); query_posts('category_name=home'); ?> in the header. home is category 4 and doesn’t need to be in the list. The list is a portfolio of services.

    The theme is from TemplateMonster.

    It’s odd that wp_list_pages is not in the header but rather in the index.php, page.php and now my home.php don’t you think? This wouldn’t cause it would it?

    I had some problems migrating from wp-list-cats to wp-list-categories as well, it could be a matter of writing the arguments (the options) correctly. I’m not saying yours is done wrong, I can’t tell. It took me several tweaks to get it to work in my theme.

    “It’s odd that wp_list_pages is not in the header but rather in the index.php, page.php and now my home.php don’t you think? This wouldn’t cause it would it?”

    I don’t think that is odd, or a problem.

    Can’t understand why Category 4 would still be appearing unless Category 4 is not what you think it is or there’s more that one template tag displaying categories.

    Please check the Category ID in Manage Categories.

    Try this:
    <?php wp_list_categories('orderby=ID&exclude=4'); ?>

    Thread Starter zomzommarketing

    (@zomzommarketing)

    Yup, Tried that with a cut and paste – no go.

    Tried this too:
    <?php wp_list_categories('orderby=ID&include=2,3,5,6,7,8,9'); ?>

    No change.

    Nothing in functions.php to change?

    Is the widgets plugin active by any chance? in that case your editing will never show up in the sidebar.

    Well if you are using widgets then changing sidebar.php may make no difference. You’d have to make the change to the widget code.

    [oops see moshu got there first]

    Thread Starter zomzommarketing

    (@zomzommarketing)

    Oh I am such a noob!

    OK, That’s what’s happening then.

    Where is that code located – I think I can handle it from here after pointing me in the right direction – thanks

    I love WordPress –

    In 2.2 it is in wp-includes/widgets.php.

    Thread Starter zomzommarketing

    (@zomzommarketing)

    OK, let’s resolve this now:

    in 2.1 widgets are still a plugin and found in the plugin folder. find widgets.php and look for this line of code
    <?php wp_list_cats...
    (mine was on line 919)
    Make the changes based on the https://codex.www.ads-software.com/Template_Tags/wp_list_cats instuctions. Mine looked like this when it was done:

    <?php wp_list_cats("sort_column=id&optioncount=$c&hierarchical=$h&exclude=1, 4"); ?>

    Thanks for letting me think out loud.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘wp_list_cats not working’ is closed to new replies.