Trying to change Events page title unsuccessfully
-
Hi there,
I’ve been trolling through loads of different forum posts here and on your Tribe site to learn how to change the title from showing the first event in the list.
I’ve found out where the the_title() code is – in header.php of my theme, U-Design.
Since my PHP knowledge is childlike at best, I’ve not been able to figure out how to implement your suggested fix with the “elseif tribe_is_month” code on your site.
Here is the code where the_title() is found:
<div id="page-title"> <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. if (is_page()) : ?> <h1><?php the_title(); ?></h1> <?php elseif ( is_single() ) : ?> <h1><?php the_title(); ?></h1> <?php elseif (is_tax()) : /* If this is a taxonomy archive */ $term = get_term_by( 'slug', get_query_var( 'term' ), get_query_var( 'taxonomy' ) ); ?> <h1 class="pagetitle"><?php echo ucwords( $term->taxonomy ) . ': ' . $term->name; ?></h1> <?php elseif (is_category()) : /* If this is a category archive */ ?> <?php if ($udesign_options['show_archive_for_string'] == 'yes') : ?> <h1 class="pagetitle"><?php single_cat_title("", true); ?></h1> <?php else : ?> <h1 class="pagetitle"><?php printf( __('Archive for the ‘%s’ Category', 'udesign' ), single_cat_title("", false) ); ?></h1> <?php endif; ?> <?php elseif (is_search()) : /* If this is a search results page */ ?> <h1 class="pagetitle"><?php printf( __('Search Results for ‘<em>%s</em>’', 'udesign' ), get_search_query() ); ?></h1> <?php elseif (is_404()) : /* If this is a 404 page */ ?> <h1 class="pagetitle"><?php esc_html_e('Page Not Found (Error 404)', 'udesign'); ?></h1> <?php elseif( is_tag() ) : /* If this is a tag archive */ ?> <h1 class="pagetitle"><?php printf( __('Posts Tagged ‘%s’', 'udesign' ), single_tag_title("", false) ); ?></h1> <?php elseif (is_day()) : /* If this is a daily archive */ ?> <h1 class="pagetitle"><?php printf( __('Archive for %s', 'udesign' ), get_the_date() ); ?></h1> <?php elseif (is_month()) : /* If this is a monthly archive */ ?> <h1 class="pagetitle"><?php printf( __('Archive for %s', 'udesign' ), get_the_time('F Y') ); ?></h1> <?php elseif (is_year()) : /* If this is a yearly archive */ ?> <h1 class="pagetitle"><?php printf( __('Archive for %s', 'udesign' ), get_the_time('Y') ); ?></h1> <?php elseif (is_author()) : /* If this is an author archive */ ?> <h1 class="pagetitle"><?php esc_html_e('Author Archive', 'udesign'); ?></h1> <?php elseif (isset($_GET['paged']) && !empty($_GET['paged'])) : /* If this is a paged archive */ ?> <h1 class="pagetitle"><?php esc_html_e('Blog Archives', 'udesign'); ?></h1> <?php else : // the case when a Title is NOT present the height should be maintained ?> <div class="no-title-present"></div> <?php endif; ?> </div>
Any idea how I can implement this title change? this is for a client’s site, and I’m scrambling to get this plugin to work for her.
Thanks,
Ryanhttps://www.ads-software.com/extend/plugins/the-events-calendar/
- The topic ‘Trying to change Events page title unsuccessfully’ is closed to new replies.