- Security: fix SQL injection vulnerability in addressbook
(CVE ID: CAN-2004-0521).
- Removed html_top and html_bottom hooks. No longer used/needed.
+ - Added "trailing text" for options built by SquirrelMail (text placed
+ after text and select list inputs on options pages)
Version 1.5.0
--------------------
setting in the user's preferences
caption The text that prefaces this setting on the preferences
page
+ trailing_text Text that follows a text input or select list input on
+ the preferences page (useful for indicating units,
+ meanings of special values, etc.)
type The type of INPUT element, which should be one of:
SMOPT_TYPE_STRING String/text input
SMOPT_TYPE_STRLIST Select list input
var $type;
var $refresh_level;
var $size;
+ var $trailing_text;
var $comment;
var $script;
var $post_script;
$this->refresh_level = $refresh_level;
$this->possible_values = $possible_values;
$this->size = SMOPT_SIZE_MEDIUM;
+ $this->trailing_text = '';
$this->comment = '';
$this->script = '';
$this->post_script = '';
$this->size = $size;
}
+ /* Set the trailing_text for this option. */
+ function setTrailingText($trailing_text) {
+ $this->trailing_text = $trailing_text;
+ }
+
/* Set the comment for this option. */
function setComment($comment) {
$this->comment = $comment;
$result = "<input type=\"text\" name=\"new_$this->name\" value=\"" .
htmlspecialchars($this->value) .
- "\" size=\"$width\" $this->script />\n";
+ "\" size=\"$width\" $this->script />$this->trailing_text\n";
return ($result);
}
}
/* Close the select tag and return our happy result. */
- $result .= "</select>\n";
+ $result .= "</select>$this->trailing_text\n";
return ($result);
}
$next_option->setSize($optset['size']);
}
+ /* If provided, set the trailing_text for this option. */
+ if (isset($optset['trailing_text'])) {
+ $next_option->setTrailingText($optset['trailing_text']);
+ }
+
/* If provided, set the comment for this option. */
if (isset($optset['comment'])) {
$next_option->setComment($optset['comment']);