1. ssssoooorrrrtttt____aaaarrrrrrrraaaayyyy((((3333)))) MMMMuuuuddddOOOOSSSS ((((5555 SSSSeeeepppp 1111999999994444)))) ssssoooorrrrtttt____aaaarrrrrrrraaaayyyy((((3333))))
    2. NNNNAAAAMMMMEEEE
    3. sort_array() - sort an array
    4. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
    5. mixed *sort_array( mixed *arr, string fun, object ob );
    6. mixed *sort_array( mixed *arr, function f );
    7. mixed *sort_array( mixed *arr, int direction );
    8. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
    9. The first form returns an array with the same elements as
    10. `arr', but quicksorted in ascending order according to the
    11. rules in `ob->fun()'. `ob->fun()' will be passed two
    12. arguments for each call. It should return -1, 0, or 1,
    13. depending on the relationship of the two arguments (lesser,
    14. equal to, greater than).
    15. The second form does the same thing but allows a function
    16. pointer to be used instead.
    17. The third form returns an array with the same elements as
    18. 'arr', but quicksorted using built-in sort routines. A
    19. 'direction' of 1 or 0 will quicksort in ascending order,
    20. while a 'direction' of -1 will quicksort in descending
    21. order. A limitation of the built-in sort routines is that
    22. the array must be homogeneous, composed entirely of a single
    23. type, where that type is string, int, or float. Arrays of
    24. arrays are sorted by sorting based on the first element,
    25. making database sorts possible.
    26. SSSSEEEEEEEE AAAALLLLSSSSOOOO
    27. filter_array(3), map_array(3), strcmp(3)
    28. Page 1 (Writen 5/23/97)