setName('search'); $this->setAction('/data/search'); $q = new Zend_Form_Element_Text('q'); $q->setRequired(true) ->addFilter('StringTrim') ->addValidator('NotEmpty'); $spam=new element_bcSpamBlock('spam'); $spam->addPrefixPath('Validator','validator/','validate') ->addValidator('SpamBlock'); $id = new Zend_Form_Element_Hidden('id'); $submit = new Zend_Form_Element_Submit('submit'); $submit->setLabel('搜索'); $this->addElements(array($q,$submit,$spam,$id)); $this->clearDecorators(); $this->addDecorator('FormElements') ->addDecorator('HtmlTag', array('tag' => '