--- lib/PXElator/html.pm 2009/08/30 16:36:37 380 +++ lib/PXElator/html.pm 2009/09/10 13:57:44 420 @@ -51,7 +51,6 @@ , qq|| - , qq|| ); } @@ -71,7 +70,7 @@ my ($ip,$conf,$format) = @_; my @editable = splice(@_,3); - warn "# conf ",dump( $ip, $conf, $format, [ @editable ] ); +# warn "# conf ",dump( $ip, $conf, $format, [ @editable ] ); $format ||= 'inline'; @@ -99,18 +98,20 @@ } elsif ( $name eq 'ssh' ) { $html =~ s{\s(\S{16}).+(\S{16})\s}{ $1..$2 }; chomp($html); + } elsif ( $name eq 'kvm' ) { + $html = qq|$html|; } - $html = qq|
$html
| + $html = qq|$html| unless $html =~ s{\b(\S+)\t(\S+)\t(\S+)\b}{$3 }gs; if ( $format =~ /edit|table/ ) { ( $name, $html ); } else { - qq|$name $html
| + qq|
$name $html
| } } - } sort keys %$conf; + } grep { length($conf->{$_}) > 0 } sort keys %$conf; $format eq 'inline' ? join("\n", @opts) : @opts; }