How to set 'selected' value in select box dropdown list?
Answer / Ankush Soni
To set the 'selected' value in a select box dropdown list, use the addMultiOption() method provided by Zend_Form_Element_Select:
```php
$select = new Zend_Form_Element_Select('fieldname');
$select->addMultiOption('option1', 'Option 1')->setValue('option1');
```
| Is This Answer Correct ? | 0 Yes | 0 No |
How can I customize the appearance of forms generated by zend_form?
How to include css and js from the controller in the zend framework?
What is autoloader in zend framework?
What is zend engine?
What is bootstrapping?
Explain what is being presented by the decorators?
How to write a program to show the function of action helper?
How to render view file from controller in zend framework?
How to install form component in zend framework?
What are the features of zend framework?
Explain the features of mvc in zend framework?
How to use update statemnet in zend framework?