Got an issue with the Yoast plugins custom canonical URLs being added to a custom template file that can't use the Yoast canonical URL, basically need a way to remove the Yoast canonical URL from one template file.
The SEO theme I develop includes it's own built in SEO, yet users still use the Yoast plugin so have to take this into account and the Yoast plugin is breaking a major SEO feature that's potentially resulting in thousands of pages not being indexed by search engines!
Have a theme feature (Stallion SEO Super Comments) that generates post like pages from larger comments. Stallion SEO Super Comments is based on the SEO Super Comments Plugin, so this will also be an issue for those plugin users as well. Example:
This feature users a separate header file (header-2.php) and separate single posts file (single-2.php), those two files are only used for this feature.
In header-2.php I use remove_action('wp_head', 'rel_canonical'); to remove the default WordPress canonical URL because the pages are generated from the comments and WordPress sets the canonical URL as the parent posts URL. If I didn't do this Google would spider the super comments pages, but not index them, would redirect link benefit etc... to the parent post.
The site above for example has around 50 posts/pages and over 1,000 comments resulting in over 1,000 pages indexed in Google with most super comments: without the super comments feature would probably have about 70 pages indexed.
I don't use the Yoast plugin, so not an issue for me, but if I did 90% of the site would be deindexed! Many of my theme users don't understand SEO too well (doesn't matter how many times I tell them don't use the Yoast plugin, they still use it), so need to idiot proof Stallion, looking for the equivalent of "remove_action('wp_head', 'rel_canonical');" for the Yoast canonical URL.
Is that possible?
Thanks in advance.