}
if ( isset( $this->data['nav_urls']['permalink'] ) && $this->data['nav_urls']['permalink'] ) {
$toolbox['permalink'] = $this->data['nav_urls']['permalink'];
- if ( $toolbox['permalink']['href'] === '' ) {
- unset( $toolbox['permalink']['href'] );
- $toolbox['ispermalink']['tooltiponly'] = true;
- $toolbox['ispermalink']['id'] = 't-ispermalink';
- $toolbox['ispermalink']['msg'] = 'permalink';
- } else {
- $toolbox['permalink']['id'] = 't-permalink';
- }
+ $toolbox['permalink']['id'] = 't-permalink';
}
if ( isset( $this->data['nav_urls']['info'] ) && $this->data['nav_urls']['info'] ) {
$toolbox['info'] = $this->data['nav_urls']['info'];
if ( isset( $item['text'] ) ) {
$text = $item['text'];
} else {
- $text = $this->translator->translate( isset( $item['msg'] ) ? $item['msg'] : $key );
+ $text = wfMessage( isset( $item['msg'] ) ? $item['msg'] : $key )->text();
}
$html = htmlspecialchars( $text );
$realAttrs = [
'type' => 'submit',
'name' => $mode,
- 'value' => $this->translator->translate(
- $mode == 'go' ? 'searcharticle' : 'searchbutton' ),
+ 'value' => wfMessage( $mode == 'go' ? 'searcharticle' : 'searchbutton' )->text(),
];
$realAttrs = array_merge(
$realAttrs,
'src' => $attrs['src'],
'alt' => isset( $attrs['alt'] )
? $attrs['alt']
- : $this->translator->translate( 'searchbutton' ),
+ : wfMessage( 'searchbutton' )->text(),
'width' => isset( $attrs['width'] ) ? $attrs['width'] : null,
'height' => isset( $attrs['height'] ) ? $attrs['height'] : null,
];