Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1077638
    Exord B.V.
    Participant

    Hi,

    The breadcrumbs doesn’t work in essential grid:

    http://thegreenhappiness.com/essential_grid/succesverhaal-minouche/

    #1077795
    Nabeel A
    Moderator

    Hi there,

    Thanks for writing in! Can you confirm that you are fully updated? (Theme and Plugins)

    You can find the latest version numbers here: (http://theme.co/changelog/) Then you can compare them to what’s installed on your site.

    If you find anything to be out of date, you can review our update guide.

    #1088248
    Exord B.V.
    Participant

    Yes I can confirm

    #1088820
    Lely
    Moderator

    Hello There,

    Essential Grid post is essentially a custom post type. Displaying a breadcrumbs on custom post type needs some customization. Please check this thread for guidance on implementing breadcrumbs:https://community.theme.co/forums/topic/custom-post-types-6/

    Hope this helps.

    #1100552
    Exord B.V.
    Participant

    Help!! I installed CTP but my whole online magazine went gone… Now I delete this plugin and my old link: http://www.thegreenhappiness.com/magazine redirect to http://www.thegreenhappiness.com

    How can I get my old link back without a redirect? 🙁

    And I still don’t know how I can get breadcrumbs at my pages.

    Please help, I have to fix this soon because we have advertising at our magazine link.

    (My English is not very good, so I hope you understand)

    #1100558
    Christopher
    Moderator

    Hi there,

    Please check your pages and make sure ‘Magazine’ slug exists.
    Breadcrumbs is displaying fine, please see : http://thegreenhappiness.com/succesverhalen/

    Hope it helps.

    #1100616
    Exord B.V.
    Participant

    The Breadcrumb is not showing when you click on a blog post.

    When I change http://www.thegreenhappiness.com/essential_grid to http://www.thegreenhappiness.com/magazine (The old url) than the magazine url doesnt work and makes a redirect to the homepage

    #1100905
    Rad
    Moderator

    Hi there,

    Would you mind providing us with login credentials so we can take a closer look? To do this, you can make a post with the following info:

    – Link to your site
    – WordPress Admin username / password
    – FTP credentials

    Don’t forget to select Set as private reply. This ensures your information is only visible to our staff.

    Thanks!

    #1101461
    Exord B.V.
    Participant
    This reply has been marked as private.
    #1101985
    Exord B.V.
    Participant

    Did you find a solution?

    #1102425
    Jade
    Moderator

    Hi there,

    I have updated the URL of the page to http://thegreenhappiness.com/magazine/ and it works fine.

    Kindly make sure that after updating the Url, you will also have to save the page.

    Thank you.

    #1103271
    Exord B.V.
    Participant

    Thank you so much!

    Now I only still need to fix the breadcrumbs.

    When you go to http://thegreenhappiness.com/magazine it works fine.
    But when you go to http://thegreenhappiness.com/essential_grid/succesverhaal-lieke-mijn-darmen-zijn-blij/ you don’t see a breadcrumb (only the home icon)

    I would like to show: [home] [magazine] [category] [title] as breadcrumb

    And is it also possible to change the url from essential_grid to magazine?

    🙂

    #1104779
    Lely
    Moderator

    Hi There,

    Unfortunately, changing the essential_grid is possible only via custom development which is outside the scope of our support. essential_grid is your permalink slug which is required when using a Custom Post type.

    Please try to add the following code on your child theme’s functions.php file:

    // Breadcrumbs
    // =============================================================================
    function x_breadcrumbs() {
    if ( x_get_option( 'x_breadcrumb_display' ) ) {
    GLOBAL $post;
    $is_ltr         = ! is_rtl();
    $stack          = x_get_stack();
    $delimiter      = x_get_breadcrumb_delimiter();
    $home_text      = x_get_breadcrumb_home_text();
    $home_link      = home_url();
    $current_before = x_get_breadcrumb_current_before();
    $current_after  = x_get_breadcrumb_current_after();
    $page_title     = get_the_title();
    $blog_title     = get_the_title( get_option( 'page_for_posts', true ) );
    if ( ! is_404() ) {
    $post_parent = $post->post_parent;
    } else {
    $post_parent = '';
    }
    if ( X_WOOCOMMERCE_IS_ACTIVE ) {
    $shop_url   = x_get_shop_link();
    $shop_title = x_get_option( 'x_' . $stack . '_shop_title' );
    $shop_link  = '<a href="'. $shop_url .'">' . $shop_title . '</a>';
    }
    echo '<div class="x-breadcrumbs"><a href="' . $home_link . '">' . $home_text . '</a>' . $delimiter;
    if ( is_home() ) {
    echo $current_before . $blog_title . $current_after;
    } elseif ( is_category() ) {
    $the_cat = get_category( get_query_var( 'cat' ), false );
    if ( $the_cat->parent != 0 ) echo get_category_parents( $the_cat->parent, TRUE, $delimiter );
    echo $current_before . single_cat_title( '', false ) . $current_after;
    } elseif ( x_is_product_category() ) {
    if ( $is_ltr ) {
    echo $shop_link . $delimiter . $current_before . single_cat_title( '', false ) . $current_after;
    } else {
    echo $current_before . single_cat_title( '', false ) . $current_after . $delimiter . $shop_link;
    }
    } elseif ( x_is_product_tag() ) {
    if ( $is_ltr ) {
    echo $shop_link . $delimiter . $current_before . single_tag_title( '', false ) . $current_after;
    } else {
    echo $current_before . single_tag_title( '', false ) . $current_after . $delimiter . $shop_link;
    }
    } elseif ( is_search() ) {
    echo $current_before . __( 'Search Results for ', '__x__' ) . '“' . get_search_query() . '”' . $current_after;
    } elseif ( is_singular( 'post' ) ) {
    if ( get_option( 'page_for_posts' ) == is_front_page() ) {
    echo $current_before . $page_title . $current_after;
    } else {
    if ( $is_ltr ) {
    echo '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>';
    }
    }
    } elseif ( is_singular( 'essential_grid' ) ) {
    if ( get_option( 'page_for_posts' ) == is_front_page() ) {
    echo $current_before . $page_title . $current_after;
    } else {
    if ( $is_ltr ) {
    echo '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>';
    }
    }
    } elseif ( x_is_portfolio() ) {
    echo $current_before . get_the_title() . $current_after;
    } elseif ( x_is_portfolio_item() ) {
    $link  = x_get_parent_portfolio_link();
    $title = x_get_parent_portfolio_title();
    if ( $is_ltr ) {
    echo '<a href="' . $link . '">' . $title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . '<a href="' . $link . '">' . $title . '</a>';
    }
    } elseif ( x_is_product() ) {
    if ( $is_ltr ) {
    echo $shop_link . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . $shop_link;
    }
    } elseif ( x_is_buddypress() ) {
    if ( bp_is_group() ) {
    echo '<a href="' . bp_get_groups_directory_permalink() . '">' . x_get_option( 'x_buddypress_groups_title' ) . '</a>' . $delimiter . $current_before . x_buddypress_get_the_title() . $current_after;
    } elseif ( bp_is_user() ) {
    echo '<a href="' . bp_get_members_directory_permalink() . '">' . x_get_option( 'x_buddypress_members_title' ) . '</a>' . $delimiter . $current_before . x_buddypress_get_the_title() . $current_after;
    } else {
    echo $current_before . x_buddypress_get_the_title() . $current_after;
    }
    } elseif ( x_is_bbpress() ) {
    remove_filter( 'bbp_no_breadcrumb', '__return_true' );
    if ( bbp_is_forum_archive() ) {
    echo $current_before . bbp_get_forum_archive_title() . $current_after;
    } else {
    echo bbp_get_breadcrumb();
    }
    add_filter( 'bbp_no_breadcrumb', '__return_true' );
    } elseif ( is_page() && ! $post_parent ) {
    echo $current_before . $page_title . $current_after;
    } elseif ( is_page() && $post_parent ) {
    $parent_id   = $post_parent;
    $breadcrumbs = array();
    if ( is_rtl() ) {
    echo $current_before . $page_title . $current_after . $delimiter;
    }
    while ( $parent_id ) {
    $page          = get_page( $parent_id );
    $breadcrumbs[] = '<a href="' . get_permalink( $page->ID ) . '">' . get_the_title( $page->ID ) . '</a>';
    $parent_id     = $page->post_parent;
    }
    if ( $is_ltr ) {
    $breadcrumbs = array_reverse( $breadcrumbs );
    }
    for ( $i = 0; $i < count( $breadcrumbs ); $i++ ) {
    echo $breadcrumbs[$i];
    if ( $i != count( $breadcrumbs ) -1 ) echo $delimiter;
    }
    if ( $is_ltr ) {
    echo $delimiter . $current_before . $page_title . $current_after;
    }
    } elseif ( is_tag() ) {
    echo $current_before . single_tag_title( '', false ) . $current_after;
    } elseif ( is_author() ) {
    GLOBAL $author;
    $userdata = get_userdata( $author );
    echo $current_before . __( 'Posts by ', '__x__' ) . '“' . $userdata->display_name . $current_after . '”';
    } elseif ( is_404() ) {
    echo $current_before . __( '404 (Page Not Found)', '__x__' ) . $current_after;
    } elseif ( is_archive() ) {
    if ( x_is_shop() ) {
    echo $current_before . $shop_title . $current_after;
    } else {
    echo $current_before . __( 'Archives ', '__x__' ) . $current_after;
    }
    }
    echo '</div>';
    }
    }
    

    From above code, look for this part:

     elseif ( is_singular( 'essential_grid' ) ) {
    if ( get_option( 'page_for_posts' ) == is_front_page() ) {
    echo $current_before . $page_title . $current_after;
    } else {
    if ( $is_ltr ) {
    echo '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>';
    }
    }
    }

    Feel free to edit on how you want it to display.

    Hope this helps.

    #1104870
    Exord B.V.
    Participant

    It worked! Thank you soooo much!

    Is it also possible to display “magazine” and the category on the breadcrumb?

    http://thegreenhappiness.com/essential_grid/recept-springrolls-met-vegan-bacon/

    #1105125
    Lely
    Moderator

    Hi There,

    You’re welcome!

    To display magazine, please update this line of code:
    echo '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    To this:

     echo '<a href="http://thegreenhappiness.com/magazine">Magazine</a>' . $delimiter . $current_before . $page_title . $current_after;
    

    From this part of the code:

     elseif ( is_singular( 'essential_grid' ) ) {
    if ( get_option( 'page_for_posts' ) == is_front_page() ) {
    echo $current_before . $page_title . $current_after;
    } else {
    if ( $is_ltr ) {
    echo '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>' . $delimiter . $current_before . $page_title . $current_after;
    } else {
    echo $current_before . $page_title . $current_after . $delimiter . '<a href="' . get_permalink( get_option( 'page_for_posts' ) ) . '">' . $blog_title . '</a>';
    }
    }
    }

    Adding categories is possible but this would be beyond the scope of our support. This would need a little more customization than normal because a post can have multiple categories.

    Further customizations from here would be getting into custom development, which is outside the scope of support we can offer. If you need more in depth changes, you may wish to consult with a developer. X is quite extensible with child themes, so there are plenty of possibilities. Thanks for understanding.

  • <script> jQuery(function($){ $("#no-reply-1077638 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>