package xm::hash;
use xm::o;
my $h = shift;
my $k;
my $T = "";
for $k (sort keys %$h)
{
$T .= "<dt class=p>".$k."</dt class=p>"
."\n<dd class=p>".$$h{$k}."</dd class=p>\n";
}
return $T;
}
my $T = shift;
my $h = { };
my $k;
$T =~ s{<dt\ class=p(?=>)((?:.(?!</?dt\ class=p>))*.)
</dt\ class=p>
\s*<dd\ class=p(?=>)((?:.(?!</?dd\ class=p>))*.)
</dd\ class=p>}{
$$h{$1} = $2;
""
}gsex;
return $h;
}
my $h = shift;
my $k;
my $T = "";
for $k (sort keys %$k)
{
$T .= "<h6 class=p>".$k."</h6 class=p>\n<dl class=p>\n";
$T .= encode1($h{$k});
$T .= "</dl class=p>\n";
}
return $T;
}
my $T = shift;
my $h = { };
my $k;
$T =~ s{<h6\ class=p(?=>)((?:.(?!</?h6\ class=p>))*.)
</h6\ class=p>
\s*<dl\ class=p(?=>)((?:.(?!</?dl\ class=p>))*.)
</dl\ class=p>}{
$$h{$1} = decode1($2);
""
}gsex;
return $h;
}
"
flatten a file - my use an encode2' file, but read it with
decode1 and then spit it out again with encode2
"};
my $in = shift;
return encode1(decode1($in));
}
return xm::o::args_stdin(@_,DESC); }
return DO(xm::o::args_stdin(@_,DESC)); }