• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Add sidebar to Events Calendar page template

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Add sidebar to Events Calendar page template

This topic is: not resolved

Tagged: events calendar, going green, Sidebar

  • This topic has 6 replies, 3 voices, and was last updated 11 years, 7 months ago by morktron.
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • September 10, 2013 at 11:44 am #61715
    derekalvarez
    Member

    I'm using the Events Calendar Pro plugin with Going Green theme and I'm trying to add my sidebar to the page template they have. Here is the code I'm using...


    <?php
    /**
    * Default Events Template
    * This file is the basic wrapper template for all the views if 'Default Events Template'
    * is selected in Events -> Settings -> Template -> Events Template.
    *
    * Override this template in your own theme by creating a file at [your-theme]/tribe-events/default-template.php
    *
    * @package TribeEventsCalendar
    * @since 3.0
    * @author Modern Tribe Inc.
    *
    */

    if ( !defined('ABSPATH') ) { die('-1'); } ?>

    <?php get_header(); ?>
    <div id="tribe-events-pg-template">
    <?php tribe_events_before_html(); ?>
    <?php tribe_get_view(); ?>
    <?php tribe_events_after_html(); ?>
    </div> <!-- #tribe-events-pg-template -->

    </div>

    <div id="sidebar" class="widget-area">

    <?php genesis_sidebar() ?>

    </div>

    <?php get_footer(); ?>

    Where am I going wrong?

    http://test.epicmag.org/events/
    September 10, 2013 at 12:45 pm #61728
    Brad Dalton
    Participant

    You may be able to conditionally change the layout using PHP code but not sure as i would need to test it locally with the plugin installed.

    Can you link to the plugin download page please.


    Tutorials for StudioPress Themes.

    September 10, 2013 at 12:47 pm #61729
    derekalvarez
    Member

    Thanks, Brad. Here it is... http://wordpress.org/plugins/the-events-calendar/

    I've changed the code a bit and it added the sidebar, but now the sidebar isn't aligning correctly...


    <?php
    /**
    * Default Events Template
    * This file is the basic wrapper template for all the views if 'Default Events Template'
    * is selected in Events -> Settings -> Template -> Events Template.
    *
    * Override this template in your own theme by creating a file at [your-theme]/tribe-events/default-template.php
    *
    * @package TribeEventsCalendar
    * @since 3.0
    * @author Modern Tribe Inc.
    *
    */

    if ( !defined('ABSPATH') ) { die('-1'); } ?>

    <?php get_header(); ?>
    <div id="content" class="content-sidebar-wrap">
    <div id="tribe-events-pg-template">
    <?php tribe_events_before_html(); ?>
    <?php tribe_get_view(); ?>
    <?php tribe_events_after_html(); ?>
    </div> <!-- #tribe-events-pg-template -->

    </div>

    <div id="sidebar" class="widget-area">

    <?php genesis_sidebar() ?>

    </div>

    <?php get_footer(); ?>

    September 10, 2013 at 1:47 pm #61750
    Brad Dalton
    Participant

    Can't you display this calender using a shortcode or PHP tag and use one of the genesis layouts instead?


    Tutorials for StudioPress Themes.

    September 10, 2013 at 2:07 pm #61752
    derekalvarez
    Member

    I might go that way, but the styling doesn't look as sharp when I tried it... I was figuring this way I'd have to change less code.

    September 10, 2013 at 5:24 pm #61810
    derekalvarez
    Member

    I figured it out for anyone else who has this problem...


    <?php
    /**
    * Default Events Template
    * This file is the basic wrapper template for all the views if 'Default Events Template'
    * is selected in Events -> Settings -> Template -> Events Template.
    *
    * Override this template in your own theme by creating a file at [your-theme]/tribe-events/default-template.php
    *
    * @package TribeEventsCalendar
    * @since 3.0
    * @author Modern Tribe Inc.
    *
    */

    if ( !defined('ABSPATH') ) { die('-1'); } ?>

    <?php get_header(); ?>

    <div id="content-sidebar-wrap">

    <div id="content">
    <div id="tribe-events-pg-template">
    <?php tribe_events_before_html(); ?>
    <?php tribe_get_view(); ?>
    <?php tribe_events_after_html(); ?>
    </div> <!-- #tribe-events-pg-template -->
    </div>

    <div id="sidebar" class="sidebar widget-area">
    <?php genesis_sidebar() ?>
    </div>

    </div> <!-- #content-sidebar-wrap -->

    <?php get_footer(); ?>

    September 25, 2014 at 9:43 pm #125762
    morktron
    Member

    Hi Derekalvarez, I've spent the whole morning trying to get Events Calendar to work with Genesis - now thanks to you I have it working 🙂

    Here is the updated code for it to work with Genesis HTML 5 themes. Just put it here: [your-theme]/tribe-events/default-template.php

    If anyone can see any errors or improvements please don't be shy.

    <?php
    /* Default Events Template - Customised for Genesis HTML5 themes */
    
    if ( !defined('ABSPATH') ) { die('-1'); }
    
    get_header(); ?>
    
    <div class="content-sidebar-wrap">
    
        <main class="content">
            <div id="tribe-events-pg-template">
                <?php tribe_events_before_html(); ?>
                <?php tribe_get_view(); ?>
                <?php tribe_events_after_html(); ?>
            </div> <!-- #tribe-events-pg-template -->
        </main>
        
        <aside id="sidebar" class="sidebar sidebar-primary widget-area">
            <?php do_action( 'genesis_sidebar' ) ?>
        </aside>
        
    </div>
    <?php get_footer(); ?>
  • Author
    Posts
Viewing 7 posts - 1 through 7 (of 7 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble