simplify sorting, fixes bug with mixed string and numeric values
This commit is contained in:
parent
8a21d03cba
commit
77f56fe462
|
@ -636,8 +636,7 @@ function parseHtml($module, $input, $values, $restricted, &$tabindex, &$tabindex
|
|||
$options = array_merge ($input[$i][$j]['options'], $input[$i][$j]['options_selected'] );
|
||||
$options = array_unique($options);
|
||||
if (!$input[$i][$j]['noSorting']) {
|
||||
if (get_preg($options[0], 'digit')) sort($options, SORT_NUMERIC);
|
||||
else sort($options, SORT_STRING);
|
||||
sort($options);
|
||||
}
|
||||
foreach ($options as $option) {
|
||||
if ($option!='') {
|
||||
|
|
Loading…
Reference in New Issue