-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added files so espresso is compatible with the event calendar plugin
- Loading branch information
1 parent
7955209
commit 606d29f
Showing
3 changed files
with
67 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php | ||
/** | ||
* If 'Default Events Template' is selected in Settings -> The Events Calendar -> Theme Settings -> Events Template, | ||
* then this file loads the page template for all ECP views except for the individual | ||
* event view. Generally, this setting should only be used if you want to manually | ||
* specify all the shell HTML of your ECP pages in this template file. Use one of the other Theme | ||
* Settings -> Events Template to automatically integrate views into your | ||
* theme. | ||
* | ||
* You can customize this view by putting a replacement file of the same name (ecp-page-template.php) in the events/ directory of your theme. | ||
*/ | ||
|
||
// Don't load directly | ||
if ( !defined('ABSPATH') ) { die('-1'); } | ||
|
||
//added this code so we can support the-events-calendar plugin | ||
|
||
$view = tribe_get_current_template(); | ||
if( basename($view) === 'gridview.php' ){ | ||
add_filter('espresso_content_layout','espresso_tec_edit_layout'); | ||
} | ||
|
||
function espresso_tec_edit_layout(){ | ||
return 'content'; | ||
} | ||
|
||
|
||
|
||
?> | ||
<?php tribe_events_before_html(); ?> | ||
<?php get_template_part('espresso-template-before'); ?> | ||
<h2 class="tribe-events-cal-title"><?php tribe_events_title(); ?></h2> | ||
<?php include(tribe_get_current_template()); ?> | ||
|
||
<?php get_template_part('espresso-template-after'); ?> | ||
<?php tribe_events_after_html(); ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
/** | ||
* If 'Default Events Template' is selected in Settings -> The Events Calendar -> Theme Settings -> Events Template, | ||
* then this file loads the page template for all for the individual | ||
* event view. Generally, this setting should only be used if you want to manually | ||
* specify all the shell HTML of your ECP pages in this template file. Use one of the other Theme | ||
* Settings -> Events Template to automatically integrate views into your | ||
* theme. | ||
* | ||
* You can customize this view by putting a replacement file of the same name (ecp-single-template.php) in the events/ directory of your theme. | ||
*/ | ||
|
||
// Don't load directly | ||
if ( !defined('ABSPATH') ) { die('-1'); } | ||
?> | ||
<?php tribe_events_before_html(); ?> | ||
<?php get_template_part('espresso-template-before'); ?> | ||
<div id="container"> | ||
<div class="tribe-events-event widecolumn"> | ||
<?php the_post(); global $post; ?> | ||
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> | ||
<h2 class="entry-title"><?php the_title(); ?></h2> | ||
<?php include(tribe_get_current_template()); ?> | ||
<?php edit_post_link(__('Edit','tribe-events-calendar'), '<span class="edit-link">', '</span>'); ?> | ||
</div><!-- post --> | ||
<?php if(tribe_get_option('showComments','no') == 'yes'){ comments_template(); } ?> | ||
</div><!-- #content --> | ||
</div><!--#container--> | ||
<?php get_template_part('espresso-template-after'); ?> | ||
<?php tribe_events_after_html(); ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters