Files @ 1f3e993156e4
Branch filter:

Location: kallithea/kallithea/templates/login.html

Mads Kiilerich
js: omit redundant type="text/javascript"

We already used plain '<script>' in several places.

https://www.w3.org/TR/html52/semantics-scripting.html#element-attrdef-script-type :
"Authors should omit the attribute, instead of redundantly giving a JavaScript
MIME type."
## -*- coding: utf-8 -*-
<%inherit file="base/root.html"/>

<%block name="title">
    ${_('Log In')}
</%block>

<%include file="/base/flash_msg.html"/>
<div class="container">
<div class="row">
<div class="centered-column">
<div id="login" class="panel panel-primary">
    <div class="panel-heading">
      <h5>
        <i class="icon-lock"></i>
        %if c.site_name:
            ${_('Log In to %s') % c.site_name}
        %else:
            ${_('Log In')}
        %endif
      </h5>
    </div>
    <div class="panel-body">
        ${h.form(url('login_home', came_from=c.came_from))}
        <div class="form">

                <div class="form-group">
                    <label class="control-label" for="username">${_('Username')}:</label>
                    <div>
                        ${h.text('username',class_='form-control')}
                    </div>
                </div>
                <div class="form-group">
                    <label class="control-label" for="password">${_('Password')}:</label>
                    <div>
                        ${h.password('password',class_='form-control')}
                    </div>
                </div>
                <div class="form-group">
                    <div>
                        <div class="checkbox">
                            <label>
                                <input type="checkbox" id="remember" name="remember"/>
                                ${_('Stay logged in after browser restart')}
                            </label>
                        </div>
                    </div>
                </div>

            <div class="form-group">
                <div>
                    ${h.link_to(_('Forgot your password ?'),h.url('reset_password'))}
                    %if h.HasPermissionAny('hg.admin', 'hg.register.auto_activate', 'hg.register.manual_activate')():
                        /
                        ${h.link_to(_("Don't have an account ?"),h.url('register'))}
                    %endif
                </div>
            </div>

            <div class="form-group">
                <div class="buttons">
                    ${h.submit('sign_in',_('Sign In'),class_="btn btn-default")}
                </div>
            </div>
        </div>
        ${h.end_form()}
        <script>
        $(document).ready(function(){
            $('#username').focus();
        });
        </script>
    </div>
</div>
</div>
</div>
</div>