apply_filters ( 'jetpack_relatedposts_filter_post_link_rel', string $link_rel, int $post->ID )

Filters the rel attribute for the Related Posts' links.

Source file: modules/related-posts/jetpack-related-posts.php

View in GitHub



(string) Link rel attribute for Related Posts’ link. Default is empty.


(int) Post ID.


Since: Jetpack 3.7.0


You can use this filter to disable the nofollow attribute that’s added to Related Posts by default. To do so, use the following snippet:

function jeherve_custom_rp_rel( $rel, $post_id ) {
    return '';
add_filter( 'jetpack_relatedposts_filter_post_link_rel', 'jeherve_custom_rp_rel', 20, 2 );

Have a note to contribute?

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s