j0k (@j0k)

Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • @j0k

    Participant

    Oh damn, here is the good syntax:

    `
    if (!is_post_type(‘forum’) && !is_post_type(‘post’) && !is_post_type(‘topic’) && !is_post_type(‘reply’)){
    if (function_exists(‘my_breadcrumb’)) my_breadcrumb();
    }
    `

    Now it works, I just have to find the “else” part with the bbPress breadcrumb to display in the theme and my problem will be resolved.

    [sorry for the multi-posts, but I can’t edit my last reply]

    @j0k

    Participant

    OK, I succeeded in doing the first thing.

    I checked in the database and found the custom post types in the wp_posts table:
    `
    if (!is_post_type(‘forum’) || !is_post_type(‘post’) || !is_post_type(‘topic’) || !is_post_type(‘reply’)){
    if (function_exists(‘my_breadcrumb’)) my_breadcrumb();
    }
    `

    The problem now is that I have to do it for all the children pages of these custom post types (forum, post, topic and reply), but I can’t find how to do it. I will try something with the get_page_children() function but I am not sure that it will work with custom posts…

Viewing 2 replies - 1 through 2 (of 2 total)