support obfuscated text fields

This commit is contained in:
Roland Gruber 2012-02-27 17:00:49 +00:00
parent e09ea0a8d6
commit 524989cfd1
1 changed files with 5 additions and 1 deletions

View File

@ -198,7 +198,7 @@ $old_options = $conf->get_moduleSettings();
// display module boxes
$tabindex = 0;
$tabindex = 1;
$modules = array_keys($options);
$_SESSION['conf_types'] = array();
for ($i = 0; $i < sizeof($modules); $i++) {
@ -259,6 +259,10 @@ function checkInput() {
if ($_SESSION['conf_types'][$element] == "text") {
$options[$element] = array($_POST[$element]);
}
// text fields
elseif ($_SESSION['conf_types'][$element] == "text_obfuscated") {
$options[$element] = array(obfuscateText($_POST[$element]));
}
// checkboxes
elseif ($_SESSION['conf_types'][$element] == "checkbox") {
if (isset($_POST[$element]) && ($_POST[$element] == "on")) $options[$element] = array('true');