WordPress.org

Ready to get started?Download WordPress

Forums

Display only top child of parent (9 posts)

  1. learningisawesome
    Member
    Posted 9 months ago #

    Hey guys i am new to wordpress and was wondering how to Display only top child of parent. What i mean by that is, let's say Movies is the top category and the child of that is Disney, Pixar etc and the child of Disney is Action and Pixar is also Action On movies category i only want to display Disney, and Pixar not Action So lets put it like this:

    Movies - Main
    -Disney (Displayed in Movies Category)
    --Action NOT DISPLAYED
    -Pixar (Displayed in Movies Category)
    --Action NOT DISPLAYED

    but wordpress automatically displays it. how would I fix this?

  2. Krishna
    Volunteer Moderator
    Posted 9 months ago #

    WordPress by default displays all listed categories including child categories. You may try a plugin like the one below or search for another one in the plugins directory.
    http://wordpress.org/plugins/collapsing-category-list/

  3. learningisawesome
    Member
    Posted 9 months ago #

    Sorry, but that isn't going to work. You see i have a template that displays posts in a given category in a page and it displays all the grandchildrens posts in the page. i dont want that, is there a php code?

  4. alchymyth
    The Sweeper & Moderator
    Posted 9 months ago #

    how to Display only top child of parent

    i have a template that displays posts in a given category in a page

    what template are you using?

    is it a page template with a custom query?

    if so, what is the full code of that template?

  5. learningisawesome
    Member
    Posted 9 months ago #

    i am using detube, the demo can be found here: http://demo.dedepress.com/detube/
    Thanks!

  6. esmi
    Forum Moderator
    Posted 9 months ago #

    I'm sorry but as you are using a commercial theme, you need to seek support from the theme's developer/vendor. We do not support commercial products here.

  7. learningisawesome
    Member
    Posted 9 months ago #

    can't I edit wordpress files to display only top child?

  8. esmi
    Forum Moderator
    Posted 9 months ago #

    No. You should never, EVER, edit WordPress core files. This is a theme issue. Contact the theme's developers.

  9. learningisawesome
    Member
    Posted 9 months ago #

    if i wanted to edit the wordpress core files, where would i find the categories options?

Reply

You must log in to post.

About this Topic