Also wrap it inside a section tag so the form's styling of gray labels
and full-width input fields doesn't apply to the CAPTCHA. The same fix
is in the new Create account form (though that uses JavaScript to
reposition the FancyCaptcha image).
CSS gives the section a small bottom margin to space it from the form
contents, small enough to not affect form layout if there is nothing
in the template header.
Bug: 47371
Change-Id: I1523fe6551585ba731b0ca4207e22d614d0a46d8
?>
<div class="mw-ui-container">
<?php
- // Some extensions including CAPTCHAs add content to header on UserLoginForm hook.
- $this->html( 'header' );
if ( $this->haveData( 'languages' ) ) {
?>
<div id="languagelinks">
?>
<div id="userloginForm">
<form name="userlogin" class="mw-ui-vform" method="post" action="<?php $this->text( 'action' ); ?>">
+ <section class="mw-form-header">
+ <?php $this->html( 'header' ); /* extensions such as ConfirmEdit add form HTML here */ ?>
+ </section>
<?php
if ( $this->data['message'] ) {
font-size: 0.8em;
}
+/* Put some space under template's header, which may contain CAPTCHA HTML.*/
+section.mw-form-header {
+ margin-bottom: 10px;
+}
+
/*
* Besides errorbox there could be warningbox, successbox, msgbox, though
* spage has never seen these in practice.