Commit | Line | Data |
---|---|---|
b6dd1aaf AC |
1 | <% if $"email" <> "" then |
2 | val email = $"email" | |
3 | val old = $"old" | |
4 | val new = $"new" | |
5 | val new2 = $"new2" | |
6 | ||
7 | if not (Pass.validEmail email) then | |
8 | %><h2><b>That is not a valid virtual mailbox address!</b></h2><% | |
9 | elseif new <> new2 then | |
10 | %><h2><b>Your new passwords do not match.</b></h2><% | |
11 | elseif not (Pass.change (email, old, new)) then | |
12 | %><h2><b>Error changing password. Did you enter the right e-mail address and current password?</b></h2><% | |
13 | else | |
14 | %><h2><b>Password changed!</b></h2><% | |
15 | end | |
16 | end %> | |
17 | ||
18 | <form action="passwd" method="post"> | |
19 | ||
20 | <table class="blanks"> | |
21 | <tr> <td>E-mail address:</td> <td><input name="email" value="<% Web.html ($"email") %>"></td> </tr> | |
22 | <tr> <td>Old password:</td> <td><input type="password" name="old"></td> </tr> | |
23 | <tr> <td>New password:</td> <td><input type="password" name="new"></td> </tr> | |
24 | <tr> <td>Confirm new password:</td> <td><input type="password" name="new2"></td> </tr> | |
25 | <tr> <td><input type="submit" value="Change"></td> </tr> | |
26 | </table> | |
27 | ||
28 | </form> |