Da manuale:

codice:
...The entries are returned in the order in which they are stored by the filesystem...
per cui trattandosi di un resource non credo sia possibile ordinarlo a monte. Credo ti convenga buttare tutto in un array ed ordinare quest'ultimo con sort()