ok, sorry.

>1. I am going to manipulate the model from the form class itself (is
>this true?)

Yes.

>>a) Do I need to declare global variable in my form class plus getter,
>>setter methods so that Controller can set that variable through those
>>methods and I can use the data provided in that variable?
>>
>yes.
>Thank You
>Daniel Latter

Yes, add a setter method for attaching the model to the form and then do
this in the controller. The form will then have access to the model to
retrieve any data it needs.

You can also populate the element directly in your controller by retrieving
it from the form and manipulating it e.g. $form->getElement('some
element')->setMultiOptions(some array).

>so what is the use of populate and setDefaults functions? 

both are used to set the values of the elements, there no difference between
the two.


-- 
View this message in context: 
http://www.nabble.com/Populating-Zend_Form_Element_Select-from-database-example-tp21761696p21766750.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to