in Phalcon\Forms\Element\Select can't set array to element

Phalson version 2.0.3 in object Phalcon\Forms\Element\Select

$select->setDefault(array('test 1', 'test 2'));
$value = $select->getValue();
var_dump($value);

string('test 2');

So return last element from array



3.0k
edited Jul '15

Maybe there the default value mean the default selected value in your select element.

The selectable values itself you define in the constructor of Phalcon\FormsElement\Select, doesn't you?