Hello everybody,
I'm trying to embed forms inside each others but as I successfully
embed them, I really don't know how to retrieve them for later
display. All examples I encounter never mention the template/view part
of this feature.
For example I have :
<pre>
class CriteriaForm extends sfForm
{
public function configure()
{
/*
* Defining filters
*/
$fields = array();
$labels = array();
$validators = array();
/*
* Static fields
*/
$fields['criteria_type'] = new sfWidgetFormInput(array('type' =>
'radio'));
$validators['criteria_type'] = new
sfValidatorChoice(array('choices' => array_keys($criteria)), array(
'required' => 'You must choose a criteria.'
));
/*
* Embeddable forms
*/
$this->embedForm('central', new CriteriaCentralForm());
$this->embedForm('store', new CriteriaStoreForm());
/*
* Validators
*/
$this->setValidators($validators);
/*
* Other stuff
*/
$this->setWidgets($fields);
$this->widgetSchema->setLabels($labels);
$this->widgetSchema->setNameFormat('criteria[%s]');
}
</pre>
Do I have to implement my own way to retrieve embed form or am I
missing something ?
I would like to access an embed form from the template/view.
Thanks a lot
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---