3
형태의 항목 유형을 얻을의 메서드 GetType의 그나마 잘 작동합니다 :Symfony2 내가 양식을 가지고 있고, BindRequest의에서 필드 형식이 필요
$peticion = $this->getRequest();
if ($peticion->getMethod() == 'POST')
{
$form->bindRequest($peticion);
if ($form->isValid()) {
foreach($form as $key => $per)
$per->getType(); // i want the type of item [text,checkbox,etc] the method getType() dont work
}}
감사합니다, 아주 좋은 –