X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2Ftemplates%2FUserlogin.php;h=4a0b413f430e400bb027517d42611cec4468d2af;hb=df59d0feb31f0868ce634bd6707085d5fada70cc;hp=adf8947cb7c70f97e7c558fb89625cdab3b34a9d;hpb=4d51a7057fc45dc5d1545ce00ab569e55b220dcc;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/templates/Userlogin.php b/includes/templates/Userlogin.php index adf8947cb7..4a0b413f43 100644 --- a/includes/templates/Userlogin.php +++ b/includes/templates/Userlogin.php @@ -56,6 +56,11 @@ class UserloginTemplate extends BaseTemplate { + data['formheader'] ) { ?> +
+ html( 'formheader' ); /* extensions such as MobileFrontend add html here */ ?> +
+
data['name'], 'text', array( 'class' => 'loginText mw-ui-input', 'id' => 'wpName1', 'tabindex' => '1', - 'size' => '20', // 'required' is blacklisted for now in Html.php due to browser issues. // Keeping here in case that changes. 'required' => true, @@ -90,14 +93,6 @@ class UserloginTemplate extends BaseTemplate { 'loginPassword mw-ui-input', 'id' => 'wpPassword1', 'tabindex' => '2', - 'size' => '20', // Set focus to this field if username is filled in. 'autofocus' => (bool)$this->data['name'], 'placeholder' => $this->getMsg( 'userlogin-yourpassword-ph' )->text() @@ -154,13 +148,13 @@ class UserloginTemplate extends BaseTemplate { 'tabindex' => '6', ); $modifiers = array( - 'mw-ui-big', 'mw-ui-block', 'mw-ui-constructive', + 'mw-ui-constructive', ); echo Html::submitButton( $this->getMsg( 'pt-login-button' )->text(), $attrs, $modifiers ); ?>
-
+ + haveData( 'createOrLoginHref' ) ) { ?> - data['loggedin'] ) { ?> -
- msg( 'userlogin-createanother' ); ?> + if ( $this->data['useemail'] && $this->data['canreset'] && $this->data['resetlink'] === true ) { + echo Html::rawElement( + 'div', + array( + 'class' => 'mw-ui-vform-field mw-form-related-link-container', + ), + Linker::link( + SpecialPage::getTitleFor( 'PasswordReset' ), + $this->getMsg( 'userlogin-resetpassword-link' )->escaped() + ) + ); + } + + if ( $this->haveData( 'createOrLoginHref' ) ) { + if ( $this->data['loggedin'] ) { ?> + -
- msg( 'userlogin-noaccount' ); ?>msg( 'userlogin-joinproject' ); ?> + - - - haveData( 'uselang' ) ) { ?> - haveData( 'token' ) ) { ?> - data['cansecurelogin'] ) {?> - data['cansecurelogin'] && $this->haveData( 'fromhttp' )) {?> + haveData( 'uselang' ) ) { + $fields .= Html::hidden( 'uselang', $this->data['uselang'] ); + } + if ( $this->haveData( 'token' ) ) { + $fields .= Html::hidden( 'wpLoginToken', $this->data['token'] ); + } + if ( $this->data['cansecurelogin'] ) { + $fields .= Html::hidden( 'wpForceHttps', $this->data['stickhttps'] ); + } + if ( $this->data['cansecurelogin'] && $this->haveData( 'fromhttp' ) ) { + $fields .= Html::hidden( 'wpFromhttp', $this->data['fromhttp'] ); + } + echo $fields; + + ?>