The vast majority of WordPress users use Yoast SEO as a plugin to improve the SEO management of their website, but WooCommerce users will have noticed a problem that arises on the Shop page, and it is that the title of the page is not displayed correctly.
At APG we usually use the following structure of variables for the Title Template:
Which should return the title “Shop | Art Project Group“, for example, but, however, for the WooCommerce Shop page the first variable appears blank, so, obviously, the title of the page is not displayed correctly: “| Art Project Group“.
To solve it we have created this small piece of PHP code which, as always, you must add to the functions.php file of your child theme to force WordPress SEO by Yoast to display the title of the Shop page correctly:
In this way the title of the Shop page will be displayed correctly.
This PHP code is sure to get you out of more than one tight spot, so we hope you find it useful.
Related posts
Comments




