in reply to Sort by what?
In the statement 'foreach my $event (sort by_title $doc->findnodes( '//program' )) {do stuff}', the 'by_title' is the name of a subroutinE that exists elsewhere in your code. This subroutine is telling the sort command how to sort.
If you want to sort based upon other criteria using the same idiom, then you could make additional subroutines.
You can find out more on sorting here and by searching this site.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Sort by what?
by Anonymous Monk on Jul 16, 2004 at 18:51 UTC |