From d9c744a4585cb5f146d3cde8b07f4e69ba7ecbe9 Mon Sep 17 00:00:00 2001 From: Luigi Pinca Date: Thu, 7 Feb 2013 16:11:58 +0100 Subject: [PATCH] fixed some wrong id attributes --- views/changepasswd.jade | 10 +++++----- views/login.jade | 6 +++--- views/recoverpasswd.jade | 11 ++++++----- views/resetpasswd.jade | 23 ++++++++--------------- views/signup.jade | 13 +++++++------ 5 files changed, 29 insertions(+), 34 deletions(-) diff --git a/views/changepasswd.jade b/views/changepasswd.jade index fac6e99..031e04a 100644 --- a/views/changepasswd.jade +++ b/views/changepasswd.jade @@ -35,30 +35,30 @@ block sections .control-group label.control-label(for="oldpassword") Old password .controls - input#username(type="password", name="oldpassword", + input#oldpassword(type="password", name="oldpassword", placeholder="enter your current password...") - if (errors.newpassword) .control-group.error label.control-label(for="newpassword") New password .controls - input#password(type="password", name="newpassword") + input#newpassword(type="password", name="newpassword") span.help-inline #{errors.newpassword} - else .control-group label.control-label(for="newpassword") New password .controls - input#password(type="password", name="newpassword", + input#newpassword(type="password", name="newpassword", placeholder="enter your new password...") - else .control-group label.control-label(for="oldpassword") Old password .controls - input#username(type="password", name="oldpassword", + input#oldpassword(type="password", name="oldpassword", placeholder="enter your current password...") .control-group label.control-label(for="password") New password .controls - input#password(type="password", name="newpassword", + input#newpassword(type="password", name="newpassword", placeholder="enter your new password...") button.submit-button.btn.btn-primary(type="submit") i.icon-edit.icon-white diff --git a/views/login.jade b/views/login.jade index ea3184f..382df57 100644 --- a/views/login.jade +++ b/views/login.jade @@ -37,14 +37,14 @@ block sections label.control-label(for="username") Name .controls input#username(type="text", name="username", - value=oldvalues.username) + maxlength="15", value=oldvalues.username) span.help-inline #{errors.username} - else .control-group label.control-label(for="username") Name .controls input#username(type="text", name="username", - value=oldvalues.username) + maxlength="15", value=oldvalues.username) - if (errors.password) .control-group.error label.control-label(for="password") Password @@ -62,7 +62,7 @@ block sections label.control-label(for="username") Name .controls input#username(type="text", name="username", - placeholder="enter your nickname...") + maxlength="15", placeholder="enter your nickname...") .control-group label.control-label(for="password") Password .controls diff --git a/views/recoverpasswd.jade b/views/recoverpasswd.jade index d52343b..c83ab09 100644 --- a/views/recoverpasswd.jade +++ b/views/recoverpasswd.jade @@ -37,21 +37,22 @@ block sections .control-group.error label.control-label(for="email") Email .controls - input#oldpassword(type="text", name="email", + input#email(type="text", name="email", value=oldvalues.email) span.help-inline #{errors.email} - else .control-group label.control-label(for="email") Email .controls - input#username(type="text", name="email", + input#email(type="text", name="email", value=oldvalues.email) - if (errors.captcha) .control-group.error label.control-label(for="captcha-input") Are you human? .controls img#captcha(src=captchaurl) - input#captcha-input(type="text", name="captcha") + input#captcha-input(type="text", name="captcha", + maxlength="4") span.help-inline #{errors.captcha} - else .control-group @@ -59,7 +60,7 @@ block sections .controls img#captcha(src=captchaurl) input#captcha-input(type="text", name="captcha", - placeholder="type what you see...") + maxlength="4", placeholder="type what you see...") - else .control-group label.control-label(for="email") Email @@ -71,7 +72,7 @@ block sections .controls img#captcha(src=captchaurl) input#captcha-input(type="text", name="captcha", - placeholder="type what you see...") + maxlength="4", placeholder="type what you see...") button.submit-button.btn.btn-primary(type="submit") i.icon-envelope.icon-white | Send password reset link diff --git a/views/resetpasswd.jade b/views/resetpasswd.jade index 2aec806..cee041e 100644 --- a/views/resetpasswd.jade +++ b/views/resetpasswd.jade @@ -18,24 +18,17 @@ block sections | #{errors.alert} form.form-horizontal.well(method="post", action="/resetpasswd?token=#{token}") fieldset - - if (locals.errors) - - if (errors.password) - .control-group.error - label.control-label(for="password") New password - .controls - input#oldpassword(type="password", name="password") - span.help-inline #{errors.password} - - else - .control-group - label.control-label(for="password") New password - .controls - input#username(type="password", name="password", - placeholder="enter your new password...") + - if (locals.errors && errors.password) + .control-group.error + label.control-label(for="password") New password + .controls + input#password(type="password", name="password") + span.help-inline #{errors.password} - else .control-group - label.control-label(for="oldpassword") New password + label.control-label(for="password") New password .controls - input#username(type="password", name="password", + input#password(type="password", name="password", placeholder="enter your new password...") button.submit-button.btn.btn-primary(type="submit") i.icon-edit.icon-white diff --git a/views/signup.jade b/views/signup.jade index 1e58dce..ee10d0c 100644 --- a/views/signup.jade +++ b/views/signup.jade @@ -39,14 +39,14 @@ block sections label.control-label(for="username") Name .controls input#username(type="text", name="username", - value=oldvalues.username) + maxlength="15", value=oldvalues.username) span.help-inline #{errors.username} - else .control-group label.control-label(for="username") Name .controls input#username(type="text", name="username", - value=oldvalues.username) + maxlength="15", value=oldvalues.username) - if (errors.email) .control-group.error label.control-label(for="email") Email @@ -77,7 +77,8 @@ block sections label.control-label(for="captcha-input") Are you human? .controls img#captcha(src=captchaurl) - input#captcha-input(type="text", name="captcha") + input#captcha-input(type="text", name="captcha", + maxlength="4") span.help-inline #{errors.captcha} - else .control-group @@ -85,13 +86,13 @@ block sections .controls img#captcha(src=captchaurl) input#captcha-input(type="text", name="captcha", - placeholder="type what you see...") + maxlength="4", placeholder="type what you see...") - else .control-group label.control-label(for="username") Name .controls input#username(type="text", name="username", - placeholder="enter a nickname...") + maxlength="15", placeholder="enter a nickname...") .control-group label.control-label(for="email") Email .controls @@ -107,7 +108,7 @@ block sections .controls img#captcha(src=captchaurl) input#captcha-input(type="text", name="captcha", - placeholder="type what you see...") + maxlength="4", placeholder="type what you see...") button.submit-button.btn.btn-success(type="submit") i.icon-user.icon-white | Sign up! -- 2.54.0