Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1014131
    ngrhd
    Participant

    Hello there!

    Please have a look here: http://sddgm.org/events/ which shows the Tribe Calendar events. However there exists no container behind the calendar. Tribe uses it’s own slug thereby generates it’s own page and I think it’s because of this it’s unable to fetch the container from X. I’ve also tried making a dedicated page and assigned its slug as events but then a notification on top comes up saying there’s a conflict between Tribe Events page and the manually generated page for they are having the same slug.

    Is it possible to assign a container using some CSS to hide the background image behind the calendar so it looks proper?

    Some screenshots:

    http://imgur.com/a/2Izs6

    Thanks

    #1014139
    Rue Nel
    Moderator

    Hello There,

    Thanks for writing in!

    To resolve this issue, 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
    
    // =============================================================================
    // SINGLE-TRIBE_EVENTS.PHP
    // -----------------------------------------------------------------------------
    // Handles output of individual posts.
    //
    // Content is output based on which Stack has been selected in the Customizer.
    // To view and/or edit the markup of your Stack's posts, first go to "views"
    // inside the "framework" subdirectory. Once inside, find your Stack's folder
    // and look for a file called "wp-single.php," where you'll be able to find the
    // appropriate output.
    // =============================================================================
    
    ?>
    
    <?php x_get_view( x_get_stack(), 'wp', 'tribe_events' ); ?>

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

    5] And again, using Notepad or TextEdit or Sublime Text or any text editor, please create another new file in your local machine.
    6] Insert the following code into that new file

    <?php
    
    // =============================================================================
    // VIEWS/INTEGRITY/WP-TRIBE_EVENTS.PHP
    // -----------------------------------------------------------------------------
    // Single post output for Integrity.
    // =============================================================================
    
    $fullwidth = get_post_meta( get_the_ID(), '_x_post_layout', true );
    
    ?>
    
    <?php get_header(); ?>
      
      <div class="x-container max width offset">
        <div class="<?php x_main_content_class(); ?>" role="main">
    
          <?php while ( have_posts() ) : the_post(); ?>
            <?php x_get_view( 'integrity', 'content', get_post_format() ); ?>
            <?php x_get_view( 'global', '_comments-template' ); ?>
          <?php endwhile; ?>
    
        </div>
    
        <?php if ( $fullwidth != 'on' ) : ?>
          <?php get_sidebar(); ?>
        <?php endif; ?>
    
      </div>
    
    <?php get_footer(); ?>

    7] Save the file named as wp-tribe_events.php
    8] 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.

    #1014241
    ngrhd
    Participant

    Hi there!

    Thank you for the code!

    I tried doing that but no luck. I’ve also flushed cache and deleted the manually added page. But still container won’t appear on the events page created by Tribe

    #1014283
    Christopher
    Moderator

    Hi there,

    Please add following code in Customize -> Custom -> CSS :

    div#tribe-events-pg-template {
        border-radius: 4px;
        box-shadow: 0 0.15em 0.35em 0 rgba(0,0,0,0.135);
        background-color: white;
        padding: 60px;
        margin: 40px auto;
    }
    body.archive.post-type-archive.post-type-archive-tribe_events {
        background-image: url("//sddgm.org/wp-content/uploads/2016/05/15803118-illustration-of-couple-playing-dandiya-on-white-background-Stock-Vector.jpg");
        background-position: right center;
    }
    

    Hope it helps.

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