X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=contrib%2Fcollectd2html.pl;h=511b3f9d585d0a8ad2bfb1ea79e396fa7b8fdbac;hb=db35efb33e81d0a013e09a8a6ffa362ad5962f7c;hp=210fd646d34f22e9a757cab8291a25bce3f437ef;hpb=4de127039456bcd34de35fc83d53501466d2a648;p=collectd.git
diff --git a/contrib/collectd2html.pl b/contrib/collectd2html.pl
index 210fd646..511b3f9d 100644
--- a/contrib/collectd2html.pl
+++ b/contrib/collectd2html.pl
@@ -68,7 +68,7 @@ $HOST = $tmp[0] if (! defined $HOST);
my $svg_p = ($IMG_FMT eq "SVG");
my $IMG_SFX = $svg_p ? ".svg" : ".png";
my $IMG_DIR = "${HOST}.dir";
-my $HTML = "${HOST}.html";
+my $HTML = "${HOST}.xhtml";
################################################################################
#
@@ -118,14 +118,20 @@ open(OUT, ">$HTML");
my $title="Rrd plot for $HOST";
print OUT <
+
END
foreach my $bn (@rrds){
my $cleaned_bn = $bn;
$cleaned_bn =~ tr/%\//__/;
print OUT <$title
-$title
+$bn
+$bn
END
# graph various ranges
- foreach my $span qw(1hour 1day 1week 1month){
+ foreach my $span (qw(1hour 1day 1week 1month)){
system("mkdir -p $IMG_DIR/" . dirname($bn));
my $img = "$IMG_DIR/${bn}-$span$IMG_SFX";
@@ -223,24 +229,28 @@ END
my $cleaned_img = $img; $cleaned_img =~ s/%/%25/g;
if (! $svg_p) {
print OUT <