Fixed array sort bug in dropdown menus

+ replaced item_id with count (now the numbering always starts with 1)