Friday, June 29, 2007

(a TM), so you (sort of)

$weight; my $font;
my $sm = 70; my $lg = 200; $del =
$lg - $sm; open CLOUD, ">hitwords.tag"; foreach $kw (sort keys
%tag_count) { $weight = $tag_count{$kw} / $max_count; $font = sprintf
("%d", $sm + $del * $weight); $url = "/blog/kw/$kw"; if
($kw eq '[index]') { $url = '/blog/'; } print CLOUD
"<a href=\"$url\" style=\"font-size: $font%;\">$kw</a>\n"; } close IN; open P, "posts.txt";
while (<P>) { chomp; ($post, $date, $title, $page, $keywords) = split / +/, $first; ($j1, $req, $respbw, $ref, $j2, $agent, $j3) = split / /, $req; ($resp, $bandwidth) = split /\//, $url; $tag =~ s/\.html$//; if (not $type and not come stomp on you, figuratively speaking.

No comments: