문제

is there a way to check inside the form class in symfony 1.3 whether it is new or not ? Tried the obvious way to check $this->isNew() but it gives an error. Thanks

도움이 되었습니까?

해결책

If your using Doctrine then you could get the object and see if that is new :

$form->getObject()->isNew();
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top