Preventing Woocommerce Pages from showing in Yoast’s Sitemap
Getting your Trinity Audio player ready... |
By default, Woocommerce adds no index tags to certain pages. This includes pages that aren’t beneficial to search, such as Cart, My Account, and Checkout. At the same time, Yoast still shows these pages in their sitemap.
In a nutshell, what we get by default is this:
What we want is this:
The following code snippet should help remove those for you: