Reputation: 28
I want to set checkbox to be checked for form rendered for specific value alone which i have retrieved from database. I can do it in jQuery, but is there any specific library functions in Symfony?
Suggestions please...
Upvotes: 1
Views: 332
Reputation: 538
you can try this....
on showing the form in first you can also pass the value in form while setting
$this->samplevariable = YOURFORM($this->getYOURMODEL->setYOURFORMFIELDNAME(array of values(1,2,3) which u get form db getYOURFORMFIELDNAME);
Upvotes: 1