Change the Meta Title for Calendar Views
-
<?php function filter_events_title( $title ) { if( tribe_context()->get( 'view_request' ) === 'default' ) { $title = 'Single event page'; } elseif( tribe_context()->get( 'view_request' ) === 'list' ) { $title = 'Single event page'; } elseif( tribe_context()->get( 'view_request' ) === 'month') { $title = 'Month event page'; } elseif( tribe_context()->get( 'view_request' ) === 'day' ) { $title = 'Day event page'; } elseif( tribe_context()->get( 'view_request' ) === 'summary' ) { $title = 'Summary event page'; } elseif( tribe_context()->get( 'view_request' ) === 'photo' ) { $title = 'Photo event page'; } elseif( tribe_context()->get( 'view_request' ) === 'map' ) { $title = 'Map event page'; } return $title; } add_filter( 'tribe_events_title_tag', 'filter_events_title' );
Hello!
I added this code from your knowledge base in functions.php of the child theme and it worked only for the first condition (‘default’), I put the same $title everywhere but it seems to need an update as in list view it changes again to “Upcoming Events” and is different in Month and Day views too (“Events for [Month]”, “Events for [Day]”), basically no other condition of this function changes the meta title. Could you tell me how to make it work please?
Best regards!
The page I need help with: [log in to see the link]
Viewing 10 replies - 1 through 10 (of 10 total)
Viewing 10 replies - 1 through 10 (of 10 total)
- The topic ‘Change the Meta Title for Calendar Views’ is closed to new replies.