id = $id; $this->action = $action; $this->elem = $elem; $this->attributes = array(); $this->style = ""; } function addAttribute($attribute, $value) { $this->attributes[] = array($attribute, $value); } function getHtml() { $html = ""; $html .= "
id."\" action=\"".$this->action."\" method=\"post\" style=\"".$this->style."\">\n"; for($i = 0; $i < count($this->attributes); $i++) $html .= "attributes[$i][0]."\" value=\"".$this->attributes[$i][1]."\">\n"; if($this->elem != null) $html .= $this->elem->getHtml(); $html .= ""; $html .= "
\n"; return $html; } } ?>