b7aac3a26c576a173dda9ac334ebe779b5006cc9
4 * options.php - Change Password HTML page
6 * Copyright (c) 2004 The SquirrelMail Project Team
7 * Licensed under the GNU GPL. For full terms see the file COPYING.
11 * @subpackage change_password
15 define('SM_PATH','../../');
17 require_once (SM_PATH
. 'include/validate.php');
18 require_once (SM_PATH
. 'functions/page_header.php');
19 require_once (SM_PATH
. 'plugins/change_password/functions.php');
20 require_once (SM_PATH
. 'plugins/change_password/config.php');
21 require_once (SM_PATH
. 'functions/forms.php');
23 /* the form was submitted, go for it */
24 if(sqgetGlobalVar('cpw_go', $cpw_go, SQ_POST
)) {
26 /* perform basic checks */
27 $Messages = cpw_check_input();
29 /* if no errors, go ahead with the actual change */
30 if(count($Messages) == 0) {
31 $Messages = cpw_do_change();
35 displayPageHeader($color, 'None');
37 do_hook('change_password_init');
41 <table align
="center" cellpadding
="2" cellspacing
="2" border
="0">
42 <tr
><td bgcolor
="<?php echo $color[0] ?>">
43 <center
><b
><?php
echo _("Change Password") ?
></b
></center
>
46 if (isset($Messages) && count($Messages) > 0) {
48 foreach ($Messages as $line) {
49 echo htmlspecialchars($line) . "<br />\n";
55 <?php
echo addForm($_SERVER['PHP_SELF'], 'POST'); ?
>
58 <th align
="right"><?php
echo _("Current Password:")?
></th
>
59 <td
><?php
echo addPwField('cpw_curpass'); ?
></td
>
62 <th align
="right"><?php
echo _("New Password:")?
></th
>
63 <td
><?php
echo addPwField('cpw_newpass'); ?
></td
>
66 <th align
=right
><?php
echo _("Verify New Password:")?
></th
>
67 <td
><?php
echo addPwField('cpw_verify'); ?
></td
>
70 <td align
="center" colspan
="2">
71 <?php
echo addSubmit(_("Change Password"), 'cpw_go'); ?
></td
>