in reply to Sort ofa Print Problem

my @stats = <DATA>; foreach my $line (sort { $a->[0] <=> $b->[0] } map { chomp; [split /\|/] } @stats) { my ($rate, $team, $comment, $gotdate) = @$line; print "$rate $team $comment\n"; print "<br>"; print "$ip $gotdate\n"; print "<br><br>"; } __DATA__ 10|A|Blah|10/1/02 14|B|Blah p9sdf kljsfd |1/6/01 4647|C|Blah adsg|15/7/02 1235|D|Blah fdfd|10/2/02
Note the $ip isn't defined anywhere. Is this a typo?

gav^

Replies are listed 'Best First'.
Re: Re: Sort ofa Print Problem
by caciqueman (Novice) on Apr 26, 2002 at 03:08 UTC
    To clarify my response:
    "it only prints the top lines and
    then returns a blank area."
    I mean that it only prints the page header,
    a few lines of html code that is above the
    sample I gave you, but the actual return
    from the amended script is now a blank area.
    Thanks.