Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1089886
    mattbuff5
    Participant

    You guys have been on point answering my questions so I’m going to the well again.

    I wan the portfolio single item view, in my case, recipes to (ex: http://greaterthanyesterdaynutrition.com/recipes/asian-chicken-lettuce-wraps-recipe/) have the same “content left, sidebar right” as the rest of my website.

    I’ve successfully gotten it to show up by editing the wp-sidebar.php and wp-single-x-portfolio.php and pasting them into the appropriate child theme directories. However as you can see in the picture below the layout / spacing is off. Any guidance as to how to correct this?

    http://prntscr.com/btnjwm

    wp-sidebar.php as in /var/www/html/wp-content/themes/x-child/framework/views/integrity

    <?php
    
    // =============================================================================
    // VIEWS/INTEGRITY/WP-SIDEBAR.PHP
    // -----------------------------------------------------------------------------
    // Sidebar output for Integrity.
    // =============================================================================
    
    ?>
    
    <?php if ( x_get_content_layout() != 'full-width' || is_singular( 'x-portfolio' ) ) : ?>
    
      <aside class="<?php x_sidebar_class(); ?>" role="complementary">
        <?php if ( get_option( 'ups_sidebars' ) != array() ) : ?>
          <?php dynamic_sidebar( apply_filters( 'ups_sidebar', 'sidebar-main' ) ); ?>
        <?php else : ?>
          <?php dynamic_sidebar( 'sidebar-main' ); ?>
        <?php endif; ?>
      </aside>
    
    <?php endif; ?>

    wp-single-x-portfolio.php as in /var/www/html/wp-content/themes/x-child/framework/views/integrity

    <?php
    
    // =============================================================================
    // VIEWS/INTEGRITY/WP-SINGLE-X-PORTFOLIO.PHP
    // -----------------------------------------------------------------------------
    // Single portfolio post output for Integrity.
    // =============================================================================
    
    ?>
    
    <?php get_header(); ?>
    
      <div class="x-container-fluid max width offset cf">
    <div class="x-main left" role="main">
            <?php while ( have_posts() ) : the_post(); ?>
              <?php x_get_view( 'integrity', 'content', 'portfolio' ); ?>
              <?php x_get_view( 'global', '_comments-template' ); ?>
            <?php endwhile; ?>
    
          </div>
              <?php get_sidebar(); ?>
      </div>
    
    <?php get_footer(); ?>
    #1089887
    mattbuff5
    Participant
    This reply has been marked as private.
    #1089936
    Thai
    Moderator

    Hi There,

    Please add the following CSS under Customizer > Custom > Global CSS:

    .single-x-portfolio .x-container-fluid.max.width.offset.cf {
        padding: 25px;
    }

    Hope it helps 🙂

    #1090053
    mattbuff5
    Participant

    worked. thanks… next question… how do i get the “Share this post” element to display at the bottom of the same column as the main recipe

    http://prntscr.com/btqw14 as seen here
    http://greaterthanyesterdaynutrition.com/recipes/asian-chicken-lettuce-wraps-recipe/

    #1090351
    Christopher
    Moderator

    Hi there,

    Please add this :

    .x-portfolio .entry-extra,.x-portfolio .entry-info {
        width: 100%;
    }

    Hope it helps.

    #1090363
    mattbuff5
    Participant

    that didn’t work, any other suggestions?

    Thanks.

    #1090452
    Christopher
    Moderator

    Hi there,

    Please add entry share shortcode in sidebar.

    [share title="Share this Post" facebook="true" twitter="true" google_plus="true" linkedin="true" pinterest="true" reddit="true" email="true"]

    Update previous code to :

    .x-portfolio .entry-info {
        width: 100%;
    }
    .x-portfolio .entry-extra{
    display:none;
    }

    Hope it helps.

    #1090640
    mattbuff5
    Participant

    Thanks that got me headed int he right direction. Below is the code i used to get the share to span the width of the single portfolio item at the very bottom of the post.

    .x-portfolio .entry-info {
        width: 100%;
    }
    .x-portfolio .entry-extra{
    display:block;
    width: 100%;
    }

    Thanks

    #1090670
    Christian
    Moderator

    Glad you’ve sorted it out.

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