* link() replaces the old functions in the makeLink() family.
*
* @since 1.18 Method exists since 1.16 as non-static, made static in 1.18.
+ * @deprecated since 1.28, use MediaWiki\Linker\LinkRenderer instead
*
* @param Title $target Can currently only be a Title, but this may
* change to support Images, literal URLs, etc.
/**
* Identical to link(), except $options defaults to 'known'.
+ *
* @since 1.16.3
+ * @deprecated since 1.28, use MediaWiki\Linker\LinkRenderer instead
* @see Linker::link
* @return string
*/
*
* If the option noBrackets is set the rollback link wont be enclosed in "[]".
*
- * See the "mediawiki.page.rollback" module for the client-side handling of this link.
- *
* @since 1.16.3. $context added in 1.20. $options added in 1.21
*
* @param Revision $rev
$inner = $context->msg( 'brackets' )->rawParams( $inner )->escaped();
}
- $context->getOutput()->addModules( 'mediawiki.page.rollback' );
-
return '<span class="mw-rollback-link">' . $inner . '</span>';
}
$query = [
'action' => 'rollback',
'from' => $rev->getUserText(),
+ 'token' => $context->getUser()->getEditToken( 'rollback' ),
];
$attrs = [
'data-mw' => 'interface',