|
@@ -62,6 +62,7 @@ class SquirrelOption {
|
|
var $type;
|
|
var $type;
|
|
var $refresh_level;
|
|
var $refresh_level;
|
|
var $size;
|
|
var $size;
|
|
|
|
+ var $trailing_text;
|
|
var $comment;
|
|
var $comment;
|
|
var $script;
|
|
var $script;
|
|
var $post_script;
|
|
var $post_script;
|
|
@@ -83,6 +84,7 @@ class SquirrelOption {
|
|
$this->refresh_level = $refresh_level;
|
|
$this->refresh_level = $refresh_level;
|
|
$this->possible_values = $possible_values;
|
|
$this->possible_values = $possible_values;
|
|
$this->size = SMOPT_SIZE_MEDIUM;
|
|
$this->size = SMOPT_SIZE_MEDIUM;
|
|
|
|
+ $this->trailing_text = '';
|
|
$this->comment = '';
|
|
$this->comment = '';
|
|
$this->script = '';
|
|
$this->script = '';
|
|
$this->post_script = '';
|
|
$this->post_script = '';
|
|
@@ -124,6 +126,11 @@ class SquirrelOption {
|
|
$this->size = $size;
|
|
$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. */
|
|
/* Set the comment for this option. */
|
|
function setComment($comment) {
|
|
function setComment($comment) {
|
|
$this->comment = $comment;
|
|
$this->comment = $comment;
|
|
@@ -210,7 +217,7 @@ class SquirrelOption {
|
|
|
|
|
|
$result = "<input type=\"text\" name=\"new_$this->name\" value=\"" .
|
|
$result = "<input type=\"text\" name=\"new_$this->name\" value=\"" .
|
|
htmlspecialchars($this->value) .
|
|
htmlspecialchars($this->value) .
|
|
- "\" size=\"$width\" $this->script />\n";
|
|
|
|
|
|
+ "\" size=\"$width\" $this->script />$this->trailing_text\n";
|
|
return ($result);
|
|
return ($result);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -237,7 +244,7 @@ class SquirrelOption {
|
|
}
|
|
}
|
|
|
|
|
|
/* Close the select tag and return our happy result. */
|
|
/* Close the select tag and return our happy result. */
|
|
- $result .= "</select>\n";
|
|
|
|
|
|
+ $result .= "</select>$this->trailing_text\n";
|
|
return ($result);
|
|
return ($result);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -436,6 +443,11 @@ function create_option_groups($optgrps, $optvals) {
|
|
$next_option->setSize($optset['size']);
|
|
$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 provided, set the comment for this option. */
|
|
if (isset($optset['comment'])) {
|
|
if (isset($optset['comment'])) {
|
|
$next_option->setComment($optset['comment']);
|
|
$next_option->setComment($optset['comment']);
|