$html = htmlspecialchars( $icon["alt"] );
}
if ( $url ) {
- $html = Html::rawElement( 'a', [ "href" => $url ], $html );
+ global $wgExternalLinkTarget;
+ $html = Html::rawElement( 'a',
+ [ "href" => $url, "target" => $wgExternalLinkTarget ],
+ $html );
}
}
return $html;
global $wgStylePath, $wgStyleVersion;
if ( $this->stylename === null ) {
- $class = get_class( $this );
+ $class = static::class;
throw new MWException( "$class::\$stylename must be set to use getSkinStylePath()" );
}