Gossamer Forum
Home : Products : Gossamer Links : Discussions :

Re: [katabd] newest links added question

Quote Reply
Re: [katabd] newest links added question In reply to
You can also add a new sub called short_title:

sub {
my $tags = shift;
my $titl = $tags->{Title} or return "No description.";
length $titl < 18 and return $titl;
my $short = substr ($titl, 0, 18);
$short =~ s/\s\S+?$//;
$short .= " ...";
return $short;
}

And then use <%short_title%> instead of <%Title%> in your link tag. This was originally written to shorten description tags, which it works great for that too.
Subject Author Views Date
Thread newest links added question katabd 1336 Nov 23, 2001, 6:52 PM
Thread Re: [katabd] newest links added question
Paul 1301 Nov 24, 2001, 3:53 AM
Thread Re: [PaulW] newest links added question
katabd 1329 Nov 24, 2001, 4:59 AM
Thread Re: [katabd] newest links added question
BryanL 1274 Nov 25, 2001, 3:35 PM
Thread Re: [BryanL] newest links added question
Paul 1273 Nov 25, 2001, 6:00 PM
Post Re: [PaulW] newest links added question
BryanL 1263 Nov 25, 2001, 8:02 PM