I changed the post slugs of several of my posts since I’m trying to follow the same naming pattern for all slugs now.
mysite.com/old-slug redirects to mysite.com/new-slug, perfect!
But I have attachments on some of my posts, and both mysite.com/old-slug/attachment and mysite.com/new-slug/attachment are indexed by search engines (old URL for the attachment doesn’t redirect to the new one).
Any way to redirect the attachments as well? Or maybe just remove the old attachment permalinks from WordPress (so it would return 404)?
I suspect that if I reset all permalinks via admin panel, post redirects would disappear as well, and I don’t want that to happen.