If you are using Woocommerce, you will notice your shop home page title is set to “Products | #site name#”. The shop title will not be able to change at the WordPress Settings -> General page. Even if you use any seo plugin, the page title will not have any effect too. It seems like Woocommerce has override all the other changes. Fortunate that Woocommerce has release a filter to modify the shop title.
To change shop title in woocommerce, follow the steps below:-
Advertisements
- Open your theme functions.php and paste the code below at the bottom and it will help you to change the woocommerce shop title
-
/** * Change the Shop archive page title. * @param string $title * @return string */ function wc_custom_shop_archive_title( $title ) { if ( is_shop() ) { return str_replace( __( 'Products', 'woocommerce' ), 'New Home Page Title', $title ); } return $title; } add_filter( 'wp_title', 'wc_custom_shop_archive_title' );
- Once save, refresh your shop page and you will notice the shop title has changed to the one that you specify
Related posts:
Woocommerce: Coupon for new customer / first order only
How to add user custom field in My Account page in Woocommerce?
Virtue Theme: How to disable broken image if featured image is set
How to hide admin bar from non admin in WordPress
WordPress: How to open rss links in new window?
Woocommerce: send email to admin when new order place (pending payment)
ContactForm7 - How to prevent user from double click on the submit button?
Free WordPress 2 Columns Kubrick Plain Theme - Red
Share this with your friends:-