Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1075498

    dbelkie
    Participant

    Hi!
    I was wondering if someone could point me in the right direction. I am wanting to move my breadcrumbs below my slider.

    I assume that I cannot move it below a “section”, so a must use a slider? If so that is OK.

    I will be putting a slider on each page as a banner, so i would like to do this as a global setting if possible.

    Here is the page:
    http://dev01.everythingcloud.com/about/

    Thanks in advance.
    Dan

    #1075936

    Rue Nel
    Moderator

    Hello Dan,

    Thanks for writing in! I have checked your about page and it looks like that you have inserted the slide inside the section within Cornerstone. I want you to remove that section for good. And then go to the settings section > Slider Settings : Below Masthead as shown below:

    You must assign your slider from here. After you have assigned it, please save your changes and preview the result. You would probably have almost the same result. We still need on more step so that we move breadcrumbs down below the slider area. Since you have your child theme active and ready, please follow the following steps below:
    1] Using Notepad or TextEdit or Sublime Text or any text editor, please create a new file in your local machine.
    2] Insert the following code into that new file

    <?php
    
    // =============================================================================
    // VIEWS/INTEGRITY/WP-HEADER.PHP
    // -----------------------------------------------------------------------------
    // Header output for Integrity.
    // =============================================================================
    
    ?>
    
    <?php x_get_view( 'global', '_header' ); ?>
    
      <?php x_get_view( 'global', '_slider-above' ); ?>
    
      <header class="<?php x_masthead_class(); ?>" role="banner">
        <?php x_get_view( 'global', '_topbar' ); ?>
        <?php x_get_view( 'global', '_navbar' ); ?>
        
      </header>
    
      <?php x_get_view( 'global', '_slider-below' ); ?>
    
      <?php x_get_view( 'integrity', '_breadcrumbs' ); ?>
    
      <?php x_get_view( 'integrity', '_landmark-header' ); ?>

    3] Save the file named as wp-header.php
    4] Upload this file to your server in the child theme’s folder
    wp-content/themes/x-child/framework/views/integrity/

    We would loved to know if this has work for you. Thank you.

    #1075958

    dbelkie
    Participant

    Thanks for the fantastic detailed response!

    It mostly worked….. I need to play around with the slider settings a bit to make things line up.

    One issue is that the breadcrumbs don’t seem to be attached to the bottom of the slider. The seem to just float down the page?
    http://prntscr.com/bpt0tn

    Also I am just wondering if this will be a global setting as I add more sliders to other pages?

    Thanks!
    Dan

    #1075972

    Rad
    Moderator

    Hi there,

    It’s not global, changes made on that slider will be available just on that slider, and will be displayed on pages where the slider is assigned.

    About the breadcrumbs, you should remove this

    .x-breadcrumb-wrap {
        position: fixed;
        width: 100%;
        z-index: 1000;
        background-color: #fafafa;
    }

    Since it’s already added after the slider, then there is no need for positioning.

    Thanks!

    #1076733

    dbelkie
    Participant

    Perfect! Works great….. but.. πŸ™‚
    One more question.

    I have added a slider to the top of the blog pages:
    http://dev01.everythingcloud.com/blog/
    http://dev01.everythingcloud.com/blog/about-dan-part-two/

    I did this in the punctions.php using the following code:

    // Adding a Slider in Blog Page
    // =============================================================================

    add_action(‘x_before_view_integrity__landmark-header’, ‘custom_blog_header’);

    function custom_blog_header() {
    if ( is_home() ) {
    echo do_shortcode(‘[rev_slider alias=”about”]’);
    }
    }

    // =============================================================================

    // Add a custom blog header image
    // =============================================================================
    add_action(‘x_before_view_integrity__landmark-header’, ‘custom_blog_header01’);
    function custom_blog_header01(){
    if (is_single() && in_category(‘Uncategorized’)) {
    echo do_shortcode(‘[rev_slider alias=”about”]’);

    }
    }

    Any chance you can advise on how to move the breadcrumbs below those sliders?

    Thanks!
    Dan

    #1077399

    Friech
    Moderator

    Hi Dan,

    You can remove or comment out the line:

    <?php x_get_view( 'integrity', '_breadcrumbs' ); ?>

    On the custom wp-header.php template provided above.

    Then on your function code, add this line:

    x_get_view( 'integrity', '_breadcrumbs' );

    below the:

    echo do_shortcode('[rev_slider alias="about"]');

    Hope it helps, Cheers!

    #1077480

    dbelkie
    Participant

    Thanks for the response.
    Hmmm Now the breadcrumbs have completely disappeared from:
    http://dev01.everythingcloud.com/about/
    and
    http://dev01.everythingcloud.com/blog/

    but they are working proper now on the axctual post page:
    http://dev01.everythingcloud.com/blog/about-dan-part-two/

    Any idea on how to get them back working on the first two?

    Dan

    #1077621

    Friech
    Moderator

    Hi Dan,

    That is because of the condition statement on your code.

    if (is_single() && in_category('Uncategorized'))

    That means the slider and breadcrumbs will only show if you’re on a single post page or on Uncategorized archive page.

    Move the breadcrumbs code outside of the if statement block.

    e.g.

    // Add a custom blog header image
    // =============================================================================
    add_action('x_before_view_integrity__landmark-header', 'custom_blog_header01');
    function custom_blog_header01(){
    if (is_single() && in_category('Uncategorized')) {
    echo do_shortcode('[rev_slider alias="about"]');
    }
    x_get_view( 'integrity', '_breadcrumbs' );
    }

    Cheers!

    #1078079

    dbelkie
    Participant

    Perfect!

    THANK YOU!
    Dan

    #1078374

    Joao
    Moderator

    Glad to hear it.

    Let us know if you need further help.

    Joao

    #1078584

    dbelkie
    Participant

    Arg!
    So sorry guys! Maybe I am not understanding the process properly. I have tried to add another blog post, and get tricky with my conditional tags in my functions.php file.

    I added a 3rd blog post, and a 3rd conditional tag (it is below and labeled “Adding a Slider to blog post Where it all started – Part Two”

    When i added this now I get two breadcrumb bars on all pages on my site. for example:
    http://dev01.everythingcloud.com/about/

    The code i used is below.
    Sorry guys, I am this si something simple?

    Dan

    // Adding Slider to the main Blog Page
    // =============================================================================

    add_action(‘x_before_view_integrity__landmark-header’, ‘custom_blog_header’);

    function custom_blog_header() {
    if ( is_home() ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    }

    // Adding a Slider to blog post Clouds Aren’t Just for Rainy Days
    // =============================================================================

    add_action(‘x_before_view_integrity__landmark-header’, ‘CloudsArentJustforRainyDays’);

    function CloudsArentJustforRainyDays() {
    if ( is_single( ‘Clouds Aren’t Just for Rainy Days’ ) ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    {
    x_get_view( ‘integrity’, ‘_breadcrumbs’ );
    }
    }

    // Adding a Slider to blog post Where it all started – Part Two
    // =============================================================================

    add_action(‘x_before_view_integrity__landmark-header’, ‘WhereitallstartedPartTwo’);

    function WhereitallstartedPartTwo() {
    if ( is_single( ‘Where it all started – Part Two’ ) ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    {
    x_get_view( ‘integrity’, ‘_breadcrumbs’ );
    }
    }

    #1079003

    Rue Nel
    Moderator

    Hello There,

    You can simply use this to prevent multiple breadcrumbs:

    // Adding a Slider to blog post Clouds Aren't Just for Rainy Days
    // =============================================================================
    
    add_action('x_before_view_integrity__landmark-header', 'CloudsArentJustforRainyDays');
    function CloudsArentJustforRainyDays() {
      if ( is_single( 'Clouds Aren't Just for Rainy Days' ) ) {
        echo do_shortcode('[rev_slider alias="blog"]');
      }
    }
    
    // Adding a Slider to blog post Where it all started – Part Two
    // =============================================================================
    
    add_action('x_before_view_integrity__landmark-header', 'WhereitallstartedPartTwo');
    function WhereitallstartedPartTwo() {
      if ( is_single( 'Where it all started – Part Two' ) ) {
        echo do_shortcode('[rev_slider alias="blog"]');
      }
    }

    And actually it is not necessary to add another function. You can just simply add a condition just like this:

    // Adding a Slider to selected blog post
    // =============================================================================
    add_action('x_before_view_integrity__landmark-header', 'add_slider_to_post');
    function add_slider_to_post() {
      if ( is_single( 'Where it all started – Part Two' ) || is_single( 'Where it all started – Part Two' ) ) {
        echo do_shortcode('[rev_slider alias="blog"]');
      }
    }

    Hope this helps.

    #1079503

    dbelkie
    Participant

    Thanks for your response.

    Because I want to have a different slider based on the title of the post, I assume I will need to add a function per post? In the example above I think would simple show the same slider for all the posts?

    I dont mind addin one per.

    OK! So….. here is where I am at now.

    I have a main blog page:
    http://dev01.everythingcloud.com/blog/
    It is working perfect. Bread crumbs on bottom.
    Code is:
    // Adding a slider to the main blog page
    // =============================================================================
    add_action(‘x_before_view_integrity__landmark-header’, ‘custom_blog_header’);
    function custom_blog_header() {
    if ( is_home() ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    }

    I have post #1:
    http://dev01.everythingcloud.com/blog/clouds-arent-just-for-rainy-days/
    It is working perfect. Bread crumbs on bottom.
    Code is:
    // Adding a slider to the clouds arnt just for rainy days post
    // =============================================================================
    add_action(‘x_before_view_integrity__landmark-header’, ‘CloudsArentJustforRainyDays’);
    function CloudsArentJustforRainyDays(){
    if (is_single( ‘Clouds Aren’t Just for Rainy Days’ ) ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    {
    x_get_view( ‘integrity’, ‘_breadcrumbs’ );
    }
    }

    I have post #2:
    http://dev01.everythingcloud.com/blog/about-dan-part-one/
    It not working proper. The breadcrumbs are on top.
    Code is:
    // Adding a slider to the Where it all started – Part One post
    // =============================================================================
    add_action(‘x_before_view_integrity__landmark-header’, ‘WhereitallstartedPartOne’);
    function WhereitallstartedPartOne(){
    if (is_single( ‘Where it all started – Part One’ ) ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    }

    I think the issue must have something to do with it not having the following:
    x_get_view( ‘integrity’, ‘_breadcrumbs’ );

    If i add that into the code like so:
    // Adding a slider to the Where it all started – Part One post
    // =============================================================================
    add_action(‘x_before_view_integrity__landmark-header’, ‘WhereitallstartedPartOne’);
    function WhereitallstartedPartOne(){
    if (is_single( ‘Where it all started – Part One’ ) ) {
    echo do_shortcode(‘[rev_slider alias=”blog”]’);
    }
    {
    x_get_view( ‘integrity’, ‘_breadcrumbs’ );
    }
    }

    I get double breadcrumbs (one on top of each other) on all pages:
    http://prntscr.com/bqus43
    http://prntscr.com/bqusbl

    And on the second post I get double breadbrumbs one on top, one on the bottom of the slider:
    http://prntscr.com/bqusma

    Thanks for helping! I know this has been painful for you guys.

    Dan

    #1079902

    Christopher
    Moderator

    Hi there,

    Please provide us with login and FTP credentials.

    Thanks.

    #1080313

    dbelkie
    Participant
    This reply has been marked as private.