Changeset 12756
- Timestamp:
- 10/15/2020 08:36:27 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-activity/bp-activity-filters.php
r12745 r12756 375 375 376 376 /** 377 * Add rel=nofollow to a link. 378 * 379 * @since 1.2.0 377 * Adds `rel="nofollow ugc"` to a link. 378 * 379 * @since 1.2.0 Adds the nofollow rel attribute. 380 * @since 7.0.0 Adds the ugc rel attribute. 380 381 * 381 382 * @param array $matches Items matched by preg_replace_callback() in bp_activity_make_nofollow_filter(). … … 384 385 function bp_activity_make_nofollow_filter_callback( $matches ) { 385 386 $text = $matches[1]; 386 $text = str_replace( array( ' rel="nofollow"', " rel='nofollow'"), '', $text ); 387 return "<a $text rel=\"nofollow\">"; 387 388 // The WP `make_clickable()` formatting function is adding the rel="nofollow" attribute. 389 $text = str_replace( array( ' rel="nofollow"', " rel='nofollow'" ), '', $text ); 390 return "<a $text rel=\"nofollow ugc\">"; 388 391 } 389 392
Note: See TracChangeset
for help on using the changeset viewer.