This list not sorted! $versions = array_keys($this->xmlhandler->extensionsXML[$extKey]['versions']); $latestVersion = end($versions); On line: 1610,1735,1382...... User this sort Function from Elmar Hinz: Own ------------------------------------------------ ------------------------------------------------ Sort: ------------------------------------------------ usort($versions, array('SC_mod_tools_em_index', 'compare')); ------------------------------------------------ ------------------------------------------------ Function: ------------------------------------------------ function compare($aIn, $bIn) { $aParts = explode('.', $aIn, 2); $bParts = explode('.', $bIn, 2); $a = (int) $aParts[0]; $b = (int) $bParts[0]; if($a > $b){ return 1; }elseif($a < $b){ return -1; } else { if(is_string($aParts[1])) { return SC_mod_tools_em_index::compare($aParts[1], $bParts[1]); } else { return 0; } } } ------------------------------------------------ ------------------------------------------------ regards Micha Barthel