Hide page name in wordpress page title
You need to Edit your theme’s Header.php tag. You will see necessary codes there. You can modify to fit your needs. However, If you need more specific help, please paste your themes header.php here. Thanks
You need to Edit your theme’s Header.php tag. You will see necessary codes there. You can modify to fit your needs. However, If you need more specific help, please paste your themes header.php here. Thanks
The title of an attachment is not working
I appreciate your comments, I have looked into a possible repeated question, however I did not find it as helpful as the last comment by @michel after looking into the functions.php file I found this filter add_filter( ‘wp_title’, ‘burger_wp_title’, 10, 2 ); function burger_excerpt_length( $length ) { return 50; } Which I have gotten rid … Read more
Yes, you can include a check for is_home() or is_front_page() and return a different title based on that. Update: TwentyEleven does it like this for example (lines 27 to 45).
CSS will not influence it. Check your theme’s functions.php file (or similar) to see if it’s transforming the title. add_filter( ‘wp_title’, ‘some_function_name’ ); You can read more about it in the Codex: https://codex.wordpress.org/Function_Reference/wp_title#Customizing_with_the_filter
Do you install any SEO plugin? Yoast SEO maybe. Or plugin that related to SEO. It usually overwrite the title setting. Check your plugin first please.
It isn’t happening to me (I just checked with your example), so it must be something that’s occurring in the theme or a plugin. You could try searching all of the codebase for the wp_title filter, but you might get a lot of results to sort through. An easier option might be switching the theme … Read more
What I actually ended up doing was to use filter document_title_parts. https://developer.wordpress.org/reference/hooks/document_title_parts/ I just unshifted a value to the array. I don’t think the documentation actually is very clear about that. And this method still don’t work with Yoast SEO installed.
You can adjust the template to use in the fly based on the type of page you’re viewing. https://codex.wordpress.org/Plugin_API/Filter_Reference/template_include add_filter( ‘template_include’, ‘portfolio_page_template’, 99 ); function portfolio_page_template( $template ) { if ( is_page( ‘portfolio’ ) ) { $new_template = locate_template( array( ‘portfolio-page-template.php’ ) ); if ( ” != $new_template ) { return $new_template ; } } … Read more
You can get all parent post id by get_post_ancestors function. add_filter( ‘document_title_parts’, ‘change_wp_title’, 20, 1 ); function change_wp_title( $title ) { global $post, $paged; $grappig = $title; // 404 if ( is_404() ) { $title[‘title’] = ‘file not available’; } elseif ( is_singular( ‘schedule’ ) ) { // get all parent post’s id $parents = … Read more