fixes bug 36, any user you edit overwrites your own account
This commit is contained in:
parent
cc25707e0a
commit
5355d9b74c
2 changed files with 2 additions and 1 deletions
|
@ -132,7 +132,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
<div class="span12">
|
<div class="span12">
|
||||||
<form name="theform" id="theform" method="get" action="users.php" class="well form-horizontal">
|
<form name="theform" id="theform" method="get" action="users.php" class="well form-horizontal">
|
||||||
{if $action == "edit" || (isset($haserror) && $action == "update")}
|
{if $action == "edit" || (isset($haserror) && $action == "update")}
|
||||||
<input type="hidden" name="userid" value="{$userid}">
|
<input type="hidden" name="userid" value="{$edituserid}">
|
||||||
<input type="hidden" name="action" value="update">
|
<input type="hidden" name="action" value="update">
|
||||||
{else if $action == "" || (isset($haserror) && $action == "insert")}
|
{else if $action == "" || (isset($haserror) && $action == "insert")}
|
||||||
<input type="hidden" name="action" value="insert">
|
<input type="hidden" name="action" value="insert">
|
||||||
|
|
|
@ -197,6 +197,7 @@ while ($row = $stmt->fetch()) {
|
||||||
}
|
}
|
||||||
|
|
||||||
$smarty->assign('action', $action);
|
$smarty->assign('action', $action);
|
||||||
|
$smarty->assign('edituserid', (int) $_GET["userid"]);
|
||||||
$smarty->assign('username', $username);
|
$smarty->assign('username', $username);
|
||||||
if (isset($username_error)) {
|
if (isset($username_error)) {
|
||||||
$smarty->assign('username_error', $username_error);
|
$smarty->assign('username_error', $username_error);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue