-
- function toStringControl() {
- if (!$this->isRenderable()) return "";
-
- if ($this->id=="") $this->id = $this->name;
-
- $html = "\n\t<input type=\"checkbox\"";
- $html .= " name=\"$this->name\" id=\"$this->id\"";
+
+ function getHtml() {
+ if ($this->id == '') $this->id = $this->name;
+
+ $html = "\n\t<input type=\"checkbox\"";
+ $html.= " id=\"$this->id\" name=\"$this->name\"";
+
+ if ($this->checked || (($this->value == $this->mOptions) && ($this->value != null)))
+ $html.= " checked=\"true\"";