projects
/
misc
/
kostenrechnung
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
721de83
)
Encode password with new users' login
author
Joey Schulze
<joey@infodrom.org>
Mon, 8 Mar 2010 08:04:48 +0000
(09:04 +0100)
committer
Joey Schulze
<joey@infodrom.org>
Mon, 8 Mar 2010 08:04:48 +0000
(09:04 +0100)
ajax/ajax.php
patch
|
blob
|
history
diff --git
a/ajax/ajax.php
b/ajax/ajax.php
index
213160a
..
f8a62c1
100644
(file)
--- a/
ajax/ajax.php
+++ b/
ajax/ajax.php
@@
-163,7
+163,8
@@
function insert($mask)
} elseif ($info['type'] == 'passwd') {
if (!empty($_POST[$field])) {
$fields[] = $field;
- $values[] = sprintf("'%s'", pg_escape_string(passwd($_SESSION['sys']['login'],$_POST[$field])));
+ $values[] = sprintf("'%s'", pg_escape_string(passwd(empty($_POST['login'])?$_SESSION['sys']['login']:$_POST['login'],
+ $_POST[$field])));
}
} else {
$fields[] = $field;