1<fieldset id="fieldset_add_user_login"> 2 <legend>{% trans 'Login Information' %}</legend> 3 <div class="item"> 4 <label for="select_pred_username">{% trans 'User name:' %}</label> 5 <span class="options"> 6 <select name="pred_username" id="select_pred_username" title="{% trans 'User name' %}"> 7 <option value="any"{{ pred_username == 'any' ? ' selected' }}>{% trans 'Any user' %}</option> 8 <option value="userdefined"{{ pred_username is null or pred_username == 'userdefined' ? ' selected' }}>{% trans 'Use text field' %}</option> 9 </select> 10 </span> 11 <input type="text" name="username" id="pma_username" class="autofocus" maxlength="{{ username_length }}" title="{% trans 'User name' %}" 12 {%- if username is not empty %} value="{{ new_username is not null ? new_username : username }}"{% endif -%} 13 {{- pred_username is null or pred_username == 'userdefined' ? ' required' }}> 14 15 <div id="user_exists_warning" class="hide"> 16 {{ 'An account already exists with the same username but possibly a different hostname.'|trans|notice }} 17 </div> 18 </div> 19 20 <div class="item"> 21 <label for="select_pred_hostname"> 22 {% trans 'Host name:' %} 23 </label> 24 <span class="options"> 25 <select name="pred_hostname" id="select_pred_hostname" title="{% trans 'Host name' %}" 26 {{- this_host is not null and this_host != 'localhost' and this_host != '127.0.0.1' ? ' data-thishost="' ~ this_host ~ '"' }}> 27 <option value="any"{{ pred_hostname == 'any' ? ' selected' }}>{% trans 'Any host' %}</option> 28 <option value="localhost"{{ pred_hostname == 'localhost' ? ' selected' }}>{% trans 'Local' %}</option> 29 {% if this_host is not empty %} 30 <option value="thishost"{{ pred_hostname == 'thishost' ? ' selected' }}>{% trans 'This host' %}</option> 31 {% endif %} 32 <option value="hosttable"{{ pred_hostname == 'hosttable' ? ' selected' }}>{% trans 'Use host table' %}</option> 33 <option value="userdefined"{{ pred_hostname == 'userdefined' ? ' selected' }}>{% trans 'Use text field' %}</option> 34 </select> 35 </span> 36 <input type="text" name="hostname" id="pma_hostname" maxlength="{{ hostname_length }}" value="{{ hostname|default('%') }}" title=" 37 {%- trans 'Host name' %}"{{ pred_hostname == 'userdefined' ? ' required' }}> 38 39 {{ show_hint('When Host table is used, this field is ignored and values stored in Host table are used instead.'|trans) }} 40 </div> 41 42 <div class="item"> 43 <label for="select_pred_password">{% trans 'Password:' %}</label> 44 <span class="options"> 45 <select name="pred_password" id="select_pred_password" title="{% trans 'Password' %}"> 46 {% if is_change %} 47 <option value="keep" selected>{% trans 'Do not change the password' %}</option> 48 {% endif %} 49 <option value="none"{{ username is not null and not is_change ? ' selected' }}>{% trans 'No password' %}</option> 50 <option value="userdefined"{{ username is null ? ' selected' }}>{% trans 'Use text field' %}</option> 51 </select> 52 </span> 53 <input type="password" id="text_pma_pw" name="pma_pw" title="{% trans 'Password' %}"{{ username is null ? ' required' }}> 54 <span>{% trans %}Strength:{% context %}Password strength{% endtrans %}</span> 55 <meter max="4" id="password_strength_meter" name="pw_meter"></meter> 56 <span id="password_strength" name="pw_strength"></span> 57 </div> 58 59 <div class="item" id="div_element_before_generate_password"> 60 <label for="text_pma_pw2">{% trans 'Re-type:' %}</label> 61 <span class="options"> </span> 62 <input type="password" name="pma_pw2" id="text_pma_pw2" title="{% trans 'Re-type' %}"{{ username is null ? ' required' }}> 63 </div> 64 65 <div class="item" id="authentication_plugin_div"> 66 <label for="select_authentication_plugin"> 67 {% if is_new %} 68 {% trans 'Authentication plugin' %} 69 {% else %} 70 {% trans 'Password hashing method' %} 71 {% endif %} 72 </label> 73 <span class="options"> </span> 74 75 <select name="authentication_plugin" id="select_authentication_plugin"> 76 {% for plugin_name, plugin_description in active_auth_plugins %} 77 <option value="{{ plugin_name }}"{{ plugin_name == auth_plugin ? ' selected' }}>{{ plugin_description }}</option> 78 {% endfor %} 79 </select> 80 81 <div id="ssl_reqd_warning"{{ auth_plugin != 'sha256_password' ? ' class="hide"' }}> 82 {% apply notice %} 83 {% trans %} 84 This method requires using an '<em>SSL connection</em>' or an '<em>unencrypted connection that encrypts the password using RSA</em>'; while connecting to the server. 85 {% endtrans %} 86 {{ show_mysql_docu('sha256-authentication-plugin') }} 87 {% endapply %} 88 </div> 89 </div> 90 {# Generate password added here via jQuery #} 91</fieldset> 92