Reputation: 215
The new MediaWiki Auth API utilizes AuthenticationRequest
s instead of plain insert-HTML-in-login-form hooks. But AuthenticationRequest::getFieldInfo
doesn't support plain HTML field type.
Is there any other way I can make an HTML AuthenticationRequest? Not a button, password or anything, just HTML tag <span>
Upvotes: 0
Views: 45
Reputation: 533
If you don't need to add any input fields, but just an information block you can use AuthChangeFormFields hook to modify authentication form html.
For example:
...
public static function onAuthChangeFormFields( $requests, $fieldInfo, &$formDescriptor, $action ) {
// Add span
$formDescriptor['my_span'] = array(
'type' => 'info',
'raw' => true,
'weight' => 500,
'default' => '<span>My span with information</span>'
);
}
...
Upvotes: 1