Tamara
Tamara

Reputation: 2980

zend framework - sort elements in subform

I have form with 3 subforms. My question is how can I sort elements within one subform. Each element has it's own order number. I tried to call _sort method like:

   $subform->_sort();

But it doesn't work. So, how can I order elements?

Upvotes: 1

Views: 263

Answers (1)

Tamara
Tamara

Reputation: 2980

For displaying form elements in right order you should use getElementsAndSubFormsOrdered() instead of getElements()

Upvotes: 2

Related Questions