123 |
|
|
124 |
my $sth = $dbh->prepare( $sql ); |
my $sth = $dbh->prepare( $sql ); |
125 |
if ($args->{search}) { |
if ($args->{search}) { |
|
warn "search for '$args->{search}' returned ", $sth->rows, " results\n"; |
|
126 |
$sth->execute( '%' . $args->{search} . '%' ); |
$sth->execute( '%' . $args->{search} . '%' ); |
127 |
|
warn "search for '$args->{search}' returned ", $sth->rows, " results\n"; |
128 |
} else { |
} else { |
129 |
$sth->execute(); |
$sth->execute(); |
130 |
} |
} |
402 |
Headers => { Server => 'irc-logger' }, |
Headers => { Server => 'irc-logger' }, |
403 |
); |
); |
404 |
|
|
405 |
|
my %escape = ('<'=>'<', '>'=>'>', '&'=>'&', '"'=>'"'); |
406 |
|
my $escape_re = join '|' => keys %escape; |
407 |
|
|
408 |
my $style = <<'_END_OF_STYLE_'; |
my $style = <<'_END_OF_STYLE_'; |
409 |
p { margin: 0; padding: 0.1em; } |
p { margin: 0; padding: 0.1em; } |
410 |
.time, .channel { color: #808080; font-size: 60%; } |
.time, .channel { color: #808080; font-size: 60%; } |
450 |
}, |
}, |
451 |
message_filter => sub { |
message_filter => sub { |
452 |
my $m = shift || return; |
my $m = shift || return; |
453 |
|
$m =~ s/($escape_re)/$escape{$1}/gs; |
454 |
$m =~ s#($RE{URI}{HTTP})#<a href="$1">$1</a>#gs; |
$m =~ s#($RE{URI}{HTTP})#<a href="$1">$1</a>#gs; |
455 |
return $m; |
return $m; |
456 |
}, |
}, |