10 # ---- PUBLIC INTERFACE --------------------------------------------------
26 $Name, $IsRequired, $Label, $Length, $Options,
27 $ValidFunc = NULL, $ValidMsgs = NULL)
29 $this->MyLength = $Length;
30 $this->MyOptions = $Options;
32 $this->
FormField($Name, $IsRequired, $Label, $ValidFunc, $ValidMsgs);
44 function Length($NewVal = NULL) {
return $this->GetOrSet(
"MyLength", $NewVal); }
51 function Options($NewVal = NULL) {
return $this->GetOrSet(
"MyOptions", $NewVal); }
64 print(
"<select name=\"".$this->MyName.
"\" size=\"".$this->MyLength.
"\">\n");
65 foreach ($this->MyOptions as $OptionValue => $OptionLabel)
67 print(
" <option value=\"".htmlspecialchars($OptionValue).
"\""
68 .(($OptionValue == $this->
Value()) ?
" selected" :
"")
69 .
">".htmlspecialchars($OptionLabel).
"\n");
76 # ---- PRIVATE INTERFACE -------------------------------------------------