]> source.dussan.org Git - nextcloud-server.git/commitdiff
Improve the password reset screen.
authorkondou <kondou@ts.unde.re>
Mon, 8 Apr 2013 05:11:35 +0000 (07:11 +0200)
committerkondou <kondou@ts.unde.re>
Tue, 23 Apr 2013 10:31:13 +0000 (12:31 +0200)
Fixing #2752

core/css/styles.css
core/lostpassword/templates/lostpassword.php

index 4dfa3f64a375c70a5ea3f9e8b524b229e5a25c45..6eea2be433de525bad1422ab8222b2c2d057174f 100644 (file)
@@ -220,6 +220,8 @@ label.infield { cursor:text !important; top:1.05em; left:.85em; }
 }
 #login #databaseField .infield { padding-left:0; }
 #login form input[type="checkbox"]+label { position:relative; margin:0; font-size:1em; text-shadow:#fff 0 1px 0; }
+#login form .errors { background:#fed7d7; border:1px solid #f00; list-style-indent:inside; margin:0 0 2em; padding:1em; }
+#login .success { background:#d7fed7; border:1px solid #0f0; width: 35%; margin: 30px auto; padding:1em; text-align: center;}
 
 /* Show password toggle */
 #show, #dbpassword { position:absolute; right:1em; top:.8em; float:right; }
index dc9f0bc8ad380b891df236caf3ffc8830ebd6fca..4009ba44050710ac38e0636577d449ea6767283e 100644 (file)
@@ -1,17 +1,31 @@
-<form action="<?php echo OC_Helper::linkToRoute('core_lostpassword_send_email') ?>" method="post">
-       <fieldset>
-               <?php echo $l->t('You will receive a link to reset your password via Email.'); ?>
-               <?php if ($_['requested']): ?>
-                       <?php echo $l->t('Reset email send.'); ?>
-               <?php else: ?>
+<?php if $_['requested']): ?>
+       <div class="success"><p>
+       <?php
+               echo $l->t('The link to reset your password has been sent to your email.');
+               echo "</p><p>";
+               echo $l->t('If you do not receive it within a reasonable amount of time, check your spam/junk folders.');
+               echo "</p><p>";
+               echo $l->t('If it is not there ask your local administrator .');
+       ?>
+       </p></div>
+<?php else: ?>
+       <form action="<?php echo OC_Helper::linkToRoute('core_lostpassword_send_email') ?>" method="post">
+               <fieldset>
                        <?php if ($_['error']): ?>
-                               <?php echo $l->t('Request failed!'); ?>
+                               <div class="errors"><p>
+                               <?php
+                                       echo $l->t('Request failed!');
+                                       echo "</p><p>";
+                                       echo $l->t('Did you make sure the Email was right?');
+                               ?>
+                               </p></div>
                        <?php endif; ?>
+                       <?php echo $l->t('You will receive a link to reset your password via Email.'); ?>
                        <p class="infield">
                                <label for="user" class="infield"><?php echo $l->t( 'Username' ); ?></label>
                                <input type="text" name="user" id="user" placeholder="" value="" autocomplete="off" required autofocus />
                        </p>
                        <input type="submit" id="submit" value="<?php echo $l->t('Request reset'); ?>" />
-               <?php endif; ?>
-       </fieldset>
-</form>
+               </fieldset>
+       </form>
+<?php endif; ?>