$elements = iterator_to_array($nodeList);
usort($elements, function($a, $b) {
return (int) $b->getAttribute('someAttribute') - (int) $a->getAttribute('someAttribute');
});
speich
.net
$elements = iterator_to_array($nodeList);
usort($elements, function($a, $b) {
return (int) $b->getAttribute('someAttribute') - (int) $a->getAttribute('someAttribute');
});