2011-11-30 2 views
0

나는 다음과 같은 코드의 조각이 있습니다, 어떤 이유안 이스케이프 문자열

// agregamos el campo de fecha de nacimiento 
$this->direccion = new Zend_Form_Element_Text('direccion'); 
$this->direccion->setLabel('Dirección:'); 
$this->direccion->setAttrib('escape', false); 
$this->direccion->getDecorator('Label')->setOption('escape',false); 
$this->direccion->setRequired(true); 
$this->addElement($this->direccion); 

() "를 Larrañaga"내용이 이스케이프하고, 아무 것도에 표시되지 않습니다 setValue에하는 동안 입력 값. 여러 게시물에서 제안 된 것처럼 setAttrib ('escape', false)가 요소에 적용됩니다.

아이디어가 있으십니까? 감사!

답변

2

당신의 init() 방법으로이 행을 추가

빠른 대답
$this->getView()->setEscape('stripslashes'); 
+0

, 감사합니다! = D –

+0

@ JoaquínL.Robles 기꺼이 도와 드리겠습니다;) –

관련 문제