allow buttons in module settings

This commit is contained in:
Roland Gruber 2012-11-25 10:55:54 +00:00
parent f9f7724438
commit 1883fe086f
1 changed files with 6 additions and 2 deletions

View File

@ -219,8 +219,8 @@ for ($i = 0; $i < sizeof($modules); $i++) {
if ($iconImage != null) {
$icon = '<img align="middle" src="../../graphics/' . $iconImage . '" alt="' . $iconImage . '"> ';
}
echo "<legend>$icon<b>" . getModuleAlias($modules[$i], "none") . "</b></legend>\n";
$configTypes = parseHtml($modules[$i], $options[$modules[$i]], $old_options, true, $tabindex, 'user');
echo "<legend>$icon" . getModuleAlias($modules[$i], "none") . "</legend>\n";
$configTypes = parseHtml($modules[$i], $options[$modules[$i]], $old_options, false, $tabindex, 'user');
$_SESSION['conf_types'] = array_merge($configTypes, $_SESSION['conf_types']);
echo "</fieldset>\n";
echo "<br>";
@ -272,6 +272,10 @@ function checkInput() {
elseif ($_SESSION['conf_types'][$element] == "text_obfuscated") {
$options[$element] = array(obfuscateText($_POST[$element]));
}
// hidden fields
elseif ($_SESSION['conf_types'][$element] == "hidden") {
$options[$element] = array($_POST[$element]);
}
// checkboxes
elseif ($_SESSION['conf_types'][$element] == "checkbox") {
if (isset($_POST[$element]) && ($_POST[$element] == "on")) $options[$element] = array('true');