_bp_maybe_remove_rel_canonical()

Remove WP’s rel=canonical HTML tag if we are trying to load BP-specific content.


Description Description

This function should be considered temporary, and may be removed without notice in future versions of BuddyPress.


Source Source

File: bp-core/bp-core-catchuri.php

function _bp_maybe_remove_rel_canonical() {
	if ( ! bp_is_blog_page() && ! is_404() ) {
		remove_action( 'wp_head', 'rel_canonical' );
		add_action( 'bp_head', 'bp_rel_canonical' );
	}
}

Top ↑

Changelog Changelog

Changelog
Version Description
1.6.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.