setCSSClass('password'); } public function generate($parent) { $value = $this->getValue(); $size = $this->getParam('size'); $maxsize = false; $size = false; if(!empty($size)) { $maxsize = $size = (int) $param['size']; if($size > 40) $size = 40; } $css = $this->getCSSClass(); $html = 'getID()) $html .= 'id="' . self::escapeString($this->getID()) . '" '; if($this->getName()) $html .= 'name="' . self::escapeString($this->getName()) . '" '; if($css) $html .= 'class="' . $css . '" '; if($this->getInlineCSS()) $html .= 'style="' . $this->getInlineCSS() . '" '; if($size !== false) $html .= 'size="' . $size . '" '; if($maxsize !== false) $html .= 'maxlength="' . $maxsize . '" '; if($value !== false) $html .= 'value="' . self::escapeString((string) $value) . '" '; if($this->isRequired()) $html .= ' onblur="validate(\'' . self::escapeString($this->getID()) . '\',\'^.+$\',\'' . $css . '\',\'' . $css . '_error\',true);" '; $html .= '/>'; return array('html' => $html); } } ?>