Skip to:
Content
Pages
Categories
Search
Top
Bottom

current in forum root


  • Jerry
    Participant

    @gerard749

    Hi,

    I don’t include home in bbp breadcrumbs. In breadcrumbs, I would like to remove current only from forum root.

    Thank You

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

  • Robkk
    Moderator

    @robkk


    Jerry
    Participant

    @gerard749

    Hi,

    #4 is how I removed home from breadcrumbs. I only want to remove current for forum root and not for topics and replies in breadcrumbs.

    Thank You


    Jerry
    Participant

    @gerard749

    Hi,

    I apologize for not explaining myself more clearly.

    I created a Forum page using Method 1 and added it to my custom menu.

    I removed my website’s home page from breadcrumbs using 4.Turning -off-or changing-breadcrumbs.

    From my custom menu, when I go to the page I created- Forums, there are 3 problems.

    1- The page title Forums is also a link to the page but I am on the page.

    2- The breadcrumbs starts with a link- Forums, the page I am on.

    3- The breadcrumbs link- Forums, is then followed by Forums but not as a link but as current page. Forums > Forums ?

    After that, when I go to a forum and then go to a topic in breadcrumbs everything is fine

    When I make the page Forums my website’s home page (Settings > Reading > Front Page Displays ) then the breadcrumbs are how I would like them to be but I don’t want the forum on my website to be the home page.

    Thank you for your time

    Jerry


    Robkk
    Moderator

    @robkk

    so your forums are displaying wrong?? and thats why you need to remove a link on the forum archive page.

    first do you have a forum named “forums”??

    because i think the breadcrumbs show like this if you have the forum root checked,

    forums>”forum name”

    if you want try unchecking use forum root in setting>forum in the backend of your site


    Jerry
    Participant

    @gerard749

    Hi,

    I apologize. It is only now I see your response.

    The forum page title was originally Forums with the slug being forums and after saving the permalinks I changed the title. In forum settings the forum root is forums.

    I now think that maybe my issue is because my WordPress website and bbPress plugin are in a subdomain.

    I apologize again for not seeing your response.

    Thank you for your time

    Jerry

    jERRY


    Jerry
    Participant

    @gerard749

    Hi,

    I have additional information.

    Even if I include my home page in breadcrumbs ($args['include_home'] = true;), on the Forum Page the page title still links to itself and in breadcrumbs there is still an additional link prior to current that links to the Forum Page – itself. Everything after that in breadcrumbs is fine.

    Thank you for your time.

    Jerry


    Robkk
    Moderator

    @robkk

    post a link to your website


    Jerry
    Participant

    @gerard749

    Hi,

    Thank you for your response

    Test1-nlcf

    Jerry


    Robkk
    Moderator

    @robkk

    ok i havent really messed with breadcrumbs that much i usually remove them but there suppose to show home > forums > forums i think from what i just tested on my localhost.

    since it shows the root anyway if you are already on the forum archive.

    but i did end up removing one of the forums link this weird way

    ok i dont know for sure what i did because i was basically just fiddling around so here are all of what i did

    i had this in my functions php in my own thematic child theme.

    function mycustom_breadcrumb_options() {
        // Home - default = true
        $args['include_home']    = false;
        // Forum root - default = true
        $args['include_root']    = true;
        // Current - default = true
        $args['include_current'] = true;
     
        return $args;
    }
     
    add_filter('bbp_before_get_breadcrumb_parse_args', 'mycustom_breadcrumb_options');
    
    add_filter( 'bbp_get_breadcrumb', 'change_breadcrumb_text' );
    
    Function change_breadcrumb_text ($trail) {
    $trail = str_replace ('No Labels Community Forum','N L C F',$trail) ;
    return $trail ;
    }

    then i removed the add_filter line for the mycustom_breadcrumb function
    so i have this now.

    function mycustom_breadcrumb_options() {
        // Home - default = true
        $args['include_home']    = false;
        // Forum root - default = true
        $args['include_root']    = true;
        // Current - default = true
        $args['include_current'] = true;
     
        return $args;
    }
    
    add_filter( 'bbp_get_breadcrumb', 'change_breadcrumb_text' );
    
    Function change_breadcrumb_text ($trail) {
    $trail = str_replace ('No Labels Community Forum','N L C F',$trail) ;
    return $trail ;
    }

    this removed one of the NLCF links in the breadcrumbs.

    i even removed the my custom breadcrumbs function and its still only shows one NLCF link…

    its weird :/


    Robkk
    Moderator

    @robkk

    @robin-w check this out it confused me alot

    am i missing something , did i do something wrong?? i have no idea how this worked on my end??


    Robkk
    Moderator

    @robkk

    dang im confusing myself big time.


    @gerard749

    i recommend you to just leave home in the breadcrumbs, so that the NLCF doesnt show up twice.


    Jerry
    Participant

    @gerard749

    Hi,

    Thank you for your response.

    Under any and all settings and configurations (including with or without Home in breadcrumbs), as far as I can see the Forum Page’s page title is also a link to itself. That link is what is appearing in breadcrumbs. The issue is not with breadcrumbs. The issue is the Forum Page’s page title being a link which also causes the issue of the additional link in breadcrumbs.

    Am I correct in assuming the Forum Page’s page title being a link is unique to my website?

    Thank You for your help

    Jerry

Viewing 12 replies - 1 through 12 (of 12 total)
  • You must be logged in to reply to this topic.
Skip to toolbar