Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Newsletter: can i SORT??

Quote Reply
Newsletter: can i SORT??
Hello, this is my first post. I try to sort the links in my newsletter, but i canīt! I want to sort by date, firts the new one... somebody can help me?

Thanks a lot!

this is the code on my db_utils.pl

sub build_new_links {
# --------------------------------------------------------
# Returns a text string used in the email newsletter of all
# new links.
#
my $output = '';
my (@data, %rec);

open (DB, "<$db_file_name") or &cgierr("unable to open db file: $db_file_name.\nReason: $!");
if ($db_use_flock) { flock(DB, 1); }
LINE: while (<DB>) {
(/^#/) and next LINE;
(/^\s*$/) and next LINE;
chomp;
@data = &split_decode($_);
if ($data[$db_isnew] eq 'm5m') {
%rec = &array_to_hash(0, @data);
my $des_q = &linewrap ($rec{'Pie'});
$output .= qq~
---------------------------------------------------------
$rec{'Title'}
$rec{'URL'}
$des_q

~;
}
}
close DB;
return $output;
}



Subject Author Views Date
Thread Newsletter: can i SORT?? jav 1073 May 20, 2000, 10:43 PM
Post Re: Newsletter: can i SORT??
Stealth 1033 May 20, 2000, 11:19 PM
Post Re: Newsletter: can i SORT??
jav 1013 May 21, 2000, 11:10 AM