Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1263195
    keethgee
    Participant

    Your “Portfolio” functionality for Renew would greatly improve if (a) the portfolio post pages could use Cornerstone and (b) there was a default/automatic way to add unique sidebar content for each portfolio post (even the “make sidebar” functionality doesn’t recognize portfolio posts).

    Having said that, since I need unique sidebars for each portfolio post, I followed the instructions on Forum answer #124165 (one instance of “ethos” in your code that I changed to “renew.”)

    You can see that there is something squirrelly still: http://jonevan17.fasttraffic.com/portfolio-item/trinity/

    (1) My wp-sidebar.php code:

    <?php

    // =============================================================================
    // VIEWS/RENEW/WP-SIDEBAR.PHP
    // —————————————————————————–
    // Sidebar output for Renew.
    // =============================================================================

    ?>

    <?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; ?>

    (1) My wp-single-x-portfolio.php code:

    <?php

    // =============================================================================
    // VIEWS/RENEW/WP-SINGLE-X-PORTFOLIO.PHP
    // —————————————————————————–
    // Single portfolio post output for Renew.
    // =============================================================================

    ?>

    <?php get_header(); ?>

    <div class=”x-container-fluid max width main”>
    <div class=”offset cf”>
    <div class=”x-main left” role=”main”>

    <?php while ( have_posts() ) : the_post(); ?>
    <?php x_get_view( ‘renew’, ‘content’, ‘portfolio’ ); ?>
    <?php x_get_view( ‘global’, ‘_comments-template’ ); ?>
    <?php endwhile; ?>

    </div>
    <?php get_sidebar(); ?>
    </div>
    </div>

    <?php get_footer(); ?>

    Thank you very much for your help!

    Keith

    #1263369
    Christopher
    Moderator

    Hi there,

    #1 Portfolio items are editable with cornerstone but not portfolio index page as its content generates automatically base on number of portfolio items.

    #2 We certainly appreciate the feedback! This is something we can add to our list of feature requests. This way it can be taken into consideration for future development. All of these items are discussed with our team internally and prioritized based on the amount of interest a particular feature might receive.

    Please update your code in wp-single-x-portfolio.php file to :

    // =============================================================================
    // VIEWS/RENEW/WP-SINGLE-X-PORTFOLIO.PHP
    // —————————————————————————–
    // Single portfolio post output for Renew.
    // =============================================================================
    
    ?>
    
    <?php get_header(); ?>
    
    <div class="x-container max width main">
    <div class="offset cf">
    <div class="x-main left" role="main">
    
    <?php while ( have_posts() ) : the_post(); ?>
    <?php x_get_view( 'renew', 'content', 'portfolio' ); ?>
    <?php x_get_view( 'global', '_comments-template' ); ?>
    <?php endwhile; ?>
    
    </div>
    <?php get_sidebar(); ?>
    </div>
    </div>
    
    <?php get_footer(); ?>

    Hope it helps.

    #1263604
    keethgee
    Participant

    Thank you, Christopher!

    (1) For anyone who reads this thread, you may find it helpful to know that you still need to add some CSS to get rid of the default Share This Project sidebar (I’m using Renew 06) and then make the portfolio image/area full width:

    .x-portfolio .entry-extra {
    display: none !important;
    }

    .x-portfolio .entry-info {
    float: left;
    width: 100% !important;
    }

    Because I can’t target portfolio page sidebars with the “add sidebar” functionality, I plan to use the “Widget Logic” plugin, which allows you to target specific pages with separate widgets within the “main sidebar” widget area. I will probably build the widget content on a throw-away page using Cornerstone, then cut/paste the shortcode results into a text widget for each portfolio page. I think that will work.

    (2) The work-around time involved with the last paragraph above is why being able to do the work directly on the portfolio pages would be sooooo much easier. Plus, I try to avoid adding more plugins due to conflict or discontinuation possibilities.

    (3) Christopher: I guess the Cornerstone access is the “shortcodes” cube icon next to the “add media” button? This is different than the “pages” interface, and so it threw me off 🙂

    Again, I truly appreciate the help.

    Keith

    #1263774
    keethgee
    Participant

    Update: I realized that Cornerstone blows up your code if you go back and forth between it and “text” view to cut/paste into a widget area. So…
    1) I activated the Visual Composer plugin that (thank you!) comes with X Theme
    2) I installed and activated the “Widget Logic” plugin
    3) I installed and activated the “Insert Pages” plugin
    4) I created a “page” for every portfolio sidebar I want to show only for a single portfolio page
    5) I put the “Insert Pages” plugin in the “Main Sidebar” widget area
    6) I entered the sidebar “page” ID in the “Insert Page” widget
    7) I put, for example, is_single( ’16’ ) in the Widget Logic area
    8) …and the “widget page” content appears (only) in my page 16 sidebar!
    9) Just add and configure a new “Insert Pages” widget into the “Main Sidebar” widget area for each unique sidebar you need
    10) I use the Yoast SEO plugin, so I am also able to try blocking spiders from indexing my sidebar pages by setting them to “no index”…although I guess if some get indexed, oh well

    There is a lot going on there, but the upshot is that I can go back to any individual “sidebar page” and edit its Visual Composer content because Cornerstone doesn’t overwrite it. Hope that helps someone else down the road 🙂

    #1263939
    Rue Nel
    Moderator

    Hello There,

    We are just glad that you have figured it out a way to correct the said issue.
    Thanks for letting us know and for sharing this very detailed instructions on how did you resolve the issue.

    Best Regards.

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