Home › Forums › Calendar Products › Events Calendar PRO › How to Change WordPress Page Title for list of Daily Events
- This topic has 7 replies, 4 voices, and was last updated 9 years, 10 months ago by
Jennifer.
-
AuthorPosts
-
June 14, 2016 at 7:46 am #1126684
Jennifer
ParticipantHi there. I’ve surfed a lot of forums in an attempt to find the answer to this, but I’m not quite sure that those solutions are correct or that I understand them.
Attached is a screenshot. I like the title that the Events Calendar is generating — “Events for June 15, 2016” is perfect. The WordPress page title (which you see is a mishmash of all of the day’s events) is awful.
I’m wondering how I can either (a) get WordPress to display that Events Calendar title as the main page title, or (b) just conditionally knock out the WordPress page title on these types of Event pages. The url for the screenshot attached is http://www.morleymanordearborn.com/events/2016-06-15/ , if that helps.
I would really appreciate if you could point me in the right direction.
Thanks!June 14, 2016 at 8:17 pm #1127120Nico
MemberHowdy Jennifer,
Welcome to our support forums and thanks for reaching out to us.
Hopefully we have a knowledgebase article covering this: Changing the browser title for calendar views. I cannot access the URL you shared with me but I’m mostly sure this is what you are looking for.
Please give it a try and let me know if it works for you,
Best,
NicoJune 16, 2016 at 8:23 am #1127902Jennifer
ParticipantHi Nico.
Thanks for the link. I think that is what I want. I just tried it, though, and crashed my site. (Whoops!)
I added the following code at the end of the functions.php file, after the last } of the previous function and right before the final ?>
/**
* Defines alternative titles for various event views.
*
* @param string $title
* @return string
*/
function filter_events_title( $title ) {
// Day view category page
elseif ( tribe_is_day() && is_tax() ) {
$title = 'Day view category page';
}
return $title;
}Do you know why adding that would have generated a 500 error? I’m pretty good with html and css, but am really a disaster with php. ?
June 17, 2016 at 10:46 pm #1128778Nico
MemberThanks for following up Jennifer!
There’s an error in the code, replace it with the sniper below (just changes the elseif for if):
function filter_events_title( $title ) {
// Day view category page
if ( tribe_is_day() && is_tax() ) {
$title = 'Day view category page';
}
return $title;
}
Please let me know if that works for you,
Best,
NicoJune 20, 2016 at 2:24 pm #1129527Jennifer
ParticipantHi Nico.
That snippet did save this time. However, it didn’t change what I was hoping it would change.
The site is now live, so you’ll be able to see this page. Take a look: http://www.morleymanordearborn.com/events/2016-06-13/
What I want to change is the WordPress title of this page, which right now is “WOMEN’S POOL, 6 PM – GAME ROOMEUCHRE, 6:30 PM – SOCIAL HALL”
Is there a way to change that?
Thanks!
JenJune 20, 2016 at 3:41 pm #1129561Nico
MemberThanks for following up Jen!
Looks like the title (and breadcrumbs) you are pointing to is being generated by the theme and not by our plugin so not sure how to change it. I think the best would be to reach out to the theme authors and ask them about it.
If you want to hide this title for calendar views just use the CSS snippet below:
/* hide theme title for event views */
.post-type-archive-tribe_events .title-header {
display: none;
}
Please let me know about it,
Best,
NicoJuly 5, 2016 at 9:35 am #1135544Support Droid
KeymasterThis topic has not been active for quite some time and will now be closed.
If you still need assistance please simply open a new topic (linking to this one if necessary)
and one of the team will be only too happy to help. -
AuthorPosts
- The topic ‘How to Change WordPress Page Title for list of Daily Events’ is closed to new replies.
