没有配置设置来执行此操作。但你可以很容易地使用 LinkerMakeExternalLink 钩。将此添加到您的 LocalSettings.php :
LinkerMakeExternalLink
LocalSettings.php
function localAddNoFollow( &$url, &$text, &$link, &$attribs ) { $bits = wfParseUrl( $url ); if ( is_array( $bits ) && isset( $bits['host'] ) ) { if ( $bits['host'] == 'www.example.com' ) { $attribs['rel']='nofollow'; } } return true; } $wgHooks['LinkerMakeExternalLink'][] = 'localAddNoFollow';