use SVG;
use Time::Piece;
use Time::Seconds;
-use Time::Simple;
use Time::HiRes;
use Tie::IxHash;
-use XML::Atom;
+use XML::Atom::Feed;
+use XML::Atom::Entry;
use XML::Generator::DBI;
use XML::SAX::Writer;
#%DB::packages = ( 'main' => 1 );
{
print "Content-Type: image/svg+xml\n\n";
- require SVG;
$date = Date::Simple->new( split /-/, $date );
$graph_bgn = $date->format('%Y-%m-%d');
$graph_end = $date->next->format('%Y-%m-%d');
$svg->rectangle( 'x' => 50, 'y' => $_ * 20 + 14, width => $width, height => 2 );
}
if ( $today ) {
- require Time::Simple;
- my $time = Time::Simple->new();
- my $x = ( $time->hours * 60 + $time->minutes ) * 0.5 + 50;
+ my $time = Time::Piece->localtime;
+ my $x = ( $time->hour * 60 + $time->minute ) * 0.5 + 50;
$svg->tag( 'line', x1 => $x, x2 => $x, y1 => 30, y2 => $tuner{all} * 20 + 20,
style => { stroke => 'red', 'fill-opacity' => '1.0' } );
}
################ mode=atom ################
if ( $mode eq 'atom' ) {
- require XML::Atom::Feed;
- require XML::Atom::Entry;
-
my $recording_count = $encoding_count = $jbk_count = 0;
my $ary_ref = $dbh->selectall_arrayref(
"SELECT chtxt, title, btime, etime, opt
################ mode=expert ################
if ( $mode eq 'expert' ) {
- require List::Compare;
-
my $ary_ref;
$HTML =~ s/%HTML_TITLE_OPT%/ - Expert/;
$HTML =~ s|%REFRESH%|<meta http-equiv="refresh" content="300">|;
$HTML .= qq {<div>\n};
- require Data::Dumper::Concise;
$tmp = read_file( '/etc/rec10.conf' );
$tmp =~ s/\n/<br>\n/gs;
$HTML .= $tmp;
}
sub get_overlap {
- require List::Util;
-
my $ary_ref = $dbh->selectall_arrayref(
"SELECT btime, etime, title
FROM timeline