When an element is marked as "ignore", the intention is that getValues() and getValidValues() should not return that element -- that's the whole purpose of the "ignore" flag in the first place. The idea is that for elements that have no purpose in your model -- such as submit and reset buttons -- you can flag them as "ignore" so that the values will not be aggregated.

If you want the value, simply don't flag it to "ignore".

Posted by Alexey Pakhomov (alpaxo) on 2010-05-27T07:01:12.000+0000

Yes, Matthew. Exactly same behavior I expect. But in recent release "ignore" flag is ignored. As I can see in trunk this was fixed with checking for

if (!$element->getIgnore()) {
...
}

Posted by Christian Albrecht (alab) on 2010-05-27T07:32:47.000+0000

Matthew, maybe that was due to my not so perfect english - the commit message was
make ... not collect ...

This functionality was either lost somewhere at the bughunt in april, or wasn't
implemented in getValidValues() before.

So now after the patch applied the behaviour is exactly what you want it to be :D