This is a perfectly normal thing to do. The title tag should have enough information in it to be useful to users when looking at their tabs. It also helps contextualise the content in search results. In both cases “About Us” would be a useless title without “- My Company LLC” attached. Pretty much every site does it.
But if you absolutely want to remove it, you can. Assuming your theme is using the modern method of adding a title tag (See here and here) and are running at least 4.4, then you can remove it with the document_title_parts filter:
function hrms_remove_site_from_title( $title ) {
unset( $title['site'] );
return $title;
}
add_filter( 'document_title_parts', 'hrms_remove_site_from_title' );
Hi Jacob,
Many thanks for filter function.
Please advice where to put this function.
I tried in functions.php and wp-includes/general-template.php but no success.
Best Regards,
Shahab
https://hrms-systems.com
-
This reply was modified 8 years, 2 months ago by
Shahab82.
functions.php, but as I said it assumes you are using the correct method for setting the title to begin with. Please see the links I included, particularly the second one. Also please take into account everything else I said. Put more bluntly that is: This is a bad idea.
The page title is getting very big by adding site title to it.
therefore I want to remove site title from page title.
May be my theme is old but I have latest version of wordpress.
therefore this solution not working for me.
Best Regards,
Shahab
https://hrms-systems.com
You theme appears to be custom-made for your site, so you should be able to make the modifications outlined in the 2nd link I posted so that this solution does work.