0
loadDefaultDecorators 함수로 데코레이터 label + HtmlTag를 제거하는 방법은 무엇입니까?Zend_Form - loadDefaultDecorators :: loadDefaultDecorators 함수를 사용하여 데코레이터를 제거하는 방법 label + HtmlTag?
내 솔루션 - 내 구현이 잘 작동하면 말해 또는 필요하세요 수정
class MyForm extend Zend_Form{
function init(){
//create form elements
......................................
}
public function loadDefaultDecorators() {
if ($this->loadDefaultDecoratorsIsDisabled()) {
return $this;
}
foreach($this->getElements()as $elem){
$elem->removeDecorator('Label')
->removeDecorator('HtmlTag');
}
return $this;
}
}
감사