Support » Fixing WordPress » [Theme Epsilon] 2.8 upgrade messed up Categories

  • Resolved CD7



    My theme does not recognize the categories after upgrade to 2.8 anymore. I’m using the epslon Theme and it has a config file, where you need to choose the category for special posts, but they aint showing up anymore there.

    Does anyone know how wp has changed dealing with categories and what could it be that I need to change?


Viewing 15 replies - 1 through 15 (of 34 total)
  • That theme uses a number of different plugins–do any of those need upgrading?

    2.8 doesn’t really do anything different with categories.

    I have upgraded all of them. I’m not using most of them anyways.

    I think your categories are okay–looks to be something in that theme’s controlpanel.php (Epsilon Theme Options). Maybe the author has an update.

    So you’re a moderator and you still haven’t figured out that there are thousands of people out there who are having this exact same problem? haha

    There seems to be an issue with the get_categories() function being called/used inside the theme’s functions.php file for every single theme I’ve tried so far.

    Call me crazy, but I’m not thinking that it’s a theme developer issue…

    Just my 2ยข

    The get_categories works fine for me.

    Using the WordPress Default theme, in wp-content/themes/default/index.php put this right before the if (have_posts()) line:

    $categories = get_categories('hide_empty=0');
    foreach ($categories as $cat) {
    	echo '<p> Cat name: ' . $cat->cat_name .'<p>';

    Do you get a list of your categories when you visit your blog?

    eight7teen–what theme are you using?

    Our Magazine by Kailoon

    Our Magazine by Kailoon looks to be a theme you purchase. Get the author to fix it.

    WOW! Gee I hadn’t thought of that… Oh wait, yes I did. The problem is that the author can’t figure out why her code that has worked perfectly in other versions of WP doesn’t work in this version.

    I’m loving the support chain here. It seems to follow a pattern:

    1. Problem reported
    2. Moderator replies asking for details
    3. Details given
    4. Moderator points to theme author
    5. End user left in dark

    That’s a definite recipe for success right there.

    eight7teen is right. It’s not a problem of the theme!

    The problem appears when you use get_categories in the funtions.php (as well in the default theme).

    Have the same problem.

    Sorry if it looks like I’m running you around.

    I don’t think it’s the get_categories in the theme’s functions.php

    I put this in the wp-content/theme/default/functions.php

    function my_list_cats() {
    $cats_array = get_categories('hide_empty=0');
    $categories = array();
    foreach ($cats_array as $cats) {
    	$categories[$cats->cat_ID] = $cats->cat_name;
    	echo '<p> Cat name: ' . $cats->cat_name .'<p>';
    echo "<pre>"; print_r($categories); echo "</pre>";

    and this in wp-content/themes/default/index.php:


    and it displayed the categories.

    Using the Epsilon theme I also changed all the occurences of get_settings with get_option to no avail.

    Michael, I posted this just in another thread, so sorry for double-posting:

    This is definitely either an undocumented feature change or a bug in WP 2.8 as the get_categories() function can not retrieve any categories when used inside functions.php – anywhere on the front-end is fine.

    To test this, include the following code to the very top of a functions.php file:

    echo '<pre>';
    echo '</pre>';

    Now, as you know, this should print out an array containing all categories on the site.
    Try this on 2.7.1 and all other older versions, the code works correctly by printing out:

        [0] => stdClass Object
                [term_id] => 3
                [name] => Tutorials
                [slug] => tutorials
                [term_group] => 0
                [term_taxonomy_id] => 3
                [taxonomy] => category
                [description] =>
                [parent] => 0
                [count] => 5
                [cat_ID] => 3
                [category_count] => 5
                [category_description] =>
                [cat_name] => Tutorials
                [category_nicename] => tutorials
                [category_parent] => 0

    However in 2.8, the following is output:

        [errors] => Array
                [invalid_taxonomy] => Array
                        [0] => Invalid Taxonomy
        [error_data] => Array

    As I stated, the code works fine in front-end files, but not in the back-end.

    This is not a problem with a theme or plugin error, as exactly the same problem is seen if you add the code to the default WordPress themes.

    danharper – see my example right before your post.

    Michael, in your example, you are creating a function in functions.php which calls get_categories(), but you use that function in a front-end file.

    Our problem is that get_categories() does not work when used solely in the back-end – ie. we’re creating a options page for our theme which requires a list of the categories.

    Try out my example, and you’ll see it does not work.

    danharper – I’ve come to accept that it’s useless to try to get him to see reason… Or any of them for that matter… I’ve done some digging, and I finally came up with a tangible result in the Trac… It seems as though they’re completely dismissing the issue there as well..

    Edit: I retract that… They’ve finally seen reason. It just took them a while.

Viewing 15 replies - 1 through 15 (of 34 total)
  • The topic ‘[Theme Epsilon] 2.8 upgrade messed up Categories’ is closed to new replies.