Something went wrong, I ask for help)))
There is a WP site with Woocommerce There are many duplicates, no matter what it is, page, category or product. Duplicates with dashes (hyphens), and with a different amount, from 2x to infinity
Now the duplicates are like this:
- site.com/category/--first-product-cat/
- site.com/category/first----product---cat/
- site.com/category/first-product-cat-/
Added
RewriteCond %{REQUEST_URI} ^(.*)--(.*)$
RewriteRule . %1-%2 [R=404,L]
That's how they all give 404
The problem is that the page usually opens as if it were a regular duplicate, but with a 404 response, but the 404 wp page does not open directly
Moreover, a 404 page exists and other non-existent pages give 404 and open a 404 page
Added ErrorDocument 404 site.com/404/ does not work
What could be? where to dig? Do not judge strictly, htaccess is not strong in rules. Maybe I'm doing something wrong initially?
P.S.
Revealed another oddity, such links give 200
- site.com/---shop/product/
- site.com/shop---/product/