title: How to populate zend form select element?
body: <p>Hello I have been searching for it from last couple of hours and have read every matching result google can give me but still can't get it to work.</p>
  
  <p>I am creating a zend form select element through:</p>
  
  <pre><code>this-&gt;addElement('select','my_select', array( 
      'label' =&gt; 'Currency', 'value' =&gt; 'blue', 
      'multiOptions' =&gt; array( 'red' =&gt; 'Rouge', 'blue' =&gt; 'Bleu', 'white' =&gt; 'Blanc', ), ) );
  </code></pre>
  
  <p>now I want to populate it through </p>
  
  <pre><code>$form-&gt;populate
  </code></pre>
  
  <p>from the controller, I have tried giving double dimensional array like</p>
  
  <pre><code>$vals = array("my_select" =&gt; array("US Dollar", "Pound Sterling")) 
  </code></pre>
  
  <p>and then giving it in:</p>
  
  <pre><code>$form-&gt;populate($vals);
  </code></pre>
  
  <p>but this didnt worked and I am not sure if this will work, at the moment I am building my array like in <code>array( 'red' =&gt; 'Rouge', 'blue' =&gt; 'Bleu', 'white' =&gt; 'Blanc')</code> the same class as zend form and then passsing it to the addElement multiOptions dynamically, as this guy suggests here:
  <a href="http://zendguru.wordpress.com/2009/03/06/zend-framework-form-working-with-dropdownselect-list/" rel="noreferrer">http://zendguru.wordpress.com/2009/03/06/zend-framework-form-working-with-dropdownselect-list/</a>
  that works but I would like to have it through populate and also if someone can suggest me how to select default value as well, I will be very grateful!</p>
  
  <p>Thanks,</p>