• Resolved simkog

    (@simkog)


    Hello,

    I have a landing page with a single Woocommerce product. I do not want to use the Shop page, so I don’t want to add it to the sitemap.

    There are two seperated sitemaps generated on my site:

    • page-sitemap1.xml
    • product-sitemap1.xml

    I can remove the Shop page from the page-sitemap1.xml by setting noindex for it. But it will be listed in the product-sitemap1.xml.

    I tried to delete the Shop page, but after that a non-exists /shop/ (my slug was different) page appeared in the product-sitemap1.xml.

    How can I completely remove the Shop page from the sitemap?

    Gergo Simko

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Benjamin Denis

    (@rainbowgeek)

    Hi,

    go to SEO, Titles and metas, Archives tab, Products and check noindex.

    Save changes.

    Thread Starter simkog

    (@simkog)

    Hi Benjamin,

    There aren’t any “Products” section under SEO > Titles & Metas > Archives tab. (tv_template is my custom post type)

    See image: https://i.imgur.com/Gw40EF6.png

    Gergo Simko

    Plugin Author Benjamin Denis

    (@rainbowgeek)

    Hum doesn’t make sense.

    You confirm you’re using WooCommerce right?

    Can you try to disable SEOPress and reactivate it to see if it’s better please?

    Thread Starter simkog

    (@simkog)

    Yes, the WooCommerce is installed and activated (as seen on the image on the previous commemt).

    I’ve removed SEOPress completely before posting here (deleted all data inside the database) as you suggest in your blog post.

    Plugin Author Benjamin Denis

    (@rainbowgeek)

    Can you try with the default WP theme (twentytwentytwo) to check if you can see your product CPT from SEO, Titles and metas, Archives tab?

    It doesn’t make sense to not see it.

    Thread Starter simkog

    (@simkog)

    Dear @rainbowgeek,

    Found the problem! Previously, I’ve hidden all Woocommerce products (there are two products on this landing site) with this snippet.

    add_filter( 'woocommerce_register_post_type_product', function( $args ) {
      $args["publicly_queryable"] = false;
      $args["public"] = false;
      return $args;
    }, 12, 1 );

    If I disable this code in my child theme’s functions.php the Products CPT will be visible in SEOPress settings.

    Plugin Author Benjamin Denis

    (@rainbowgeek)

    OK, that makes sense now 🙂

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Remove /shop/ page from sitemaps’ is closed to new replies.