rel=canonical missing on whole site, except anspress pages

7.63K viewsIssues
1

Hi.

I’m using Anspress, but I realised it removes all rel=canonical tags placed by Yoast SEO on my website.

I found this function in /includes/class-theme.php, but I don’t know why it remove canonical on the other pages / taxonomies, it should only replace it on question taxonomy.

$this->ap->add_filter( 'wpseo_canonical', $this, 'wpseo_canonical' );
...
public function wpseo_canonical() {
	if ( is_question() ) {
		return get_permalink( get_question_id() ); }
	}

Is there any workaround for this, except replacing Yoast SEO with another SEO plugin.

Thanks in advance,

Cristian

0

This is still an issue. Any update on when a fix will be released?

commented on answer

Hello, This issue was already solved in AnsPress 4.

Oh ok, I didn’t realize there was a new version. I see the announcement now. Thanks. Can we uninstall “Categories for AnsPress” add-on plugin now that everything is included in core?

You are viewing 1 out of 3 answers, click here to view all answers.