summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
authorMarc Green <marcgreen@cpan.org>2011-06-09 09:33:42 -0400
committerMarc Green <marcgreen@cpan.org>2011-10-31 13:26:39 -0400
commit401f7940ed76c4c7c1fa64f827daa4db1fb0dc9f (patch)
treebe1962b0883d423fa452b2cfc13c773d2201e66e /ext
parent3ada32a32931e57ec7cf57dd0882e98b7ba05226 (diff)
downloadperl-401f7940ed76c4c7c1fa64f827daa4db1fb0dc9f.tar.gz
Reimplement --header, $bodystyle, $tdstyle
Diffstat (limited to 'ext')
-rw-r--r--ext/Pod-Html/lib/Pod/Html.pm27
1 files changed, 19 insertions, 8 deletions
diff --git a/ext/Pod-Html/lib/Pod/Html.pm b/ext/Pod-Html/lib/Pod/Html.pm
index 19dd84f6a2..cfce24b42d 100644
--- a/ext/Pod-Html/lib/Pod/Html.pm
+++ b/ext/Pod-Html/lib/Pod/Html.pm
@@ -259,7 +259,7 @@ sub pod2html {
parse_command_line();
# Get the full path
- $Podpath = map { $Podroot.$_ } @Podpath;
+ @Podpath = map { $Podroot.$_ } @Podpath;
# finds all pod modules/pages in podpath, stores in %Pages
# --recurse is implemented in _save_page for now (its inefficient right now)
@@ -276,22 +276,26 @@ sub pod2html {
$parser->quiet($Quiet);
$parser->verbose($Verbose);
- # TODO: implement default title generator in here/::xhtml
+ # TODO: implement default title generator in ::xhtml
$Title = html_escape($Title);
+ my $csslink = '';
+ my $bodystyle = ' style="background-color: white"';
+ my $tdstyle = ' style="background-color: #cccccc"';
+
if ($Css) {
$csslink = qq(\n<link rel="stylesheet" href="$Css" type="text/css" />);
$csslink =~ s,\\,/,g;
$csslink =~ s,(/.):,$1|,;
+ $bodystyle = '';
+ $tdstyle= '';
}
- # left off here - determine what to do with class="(_)block"
- # do $parser->html_footer with $block
-
+ # header/footer block
my $block = $Header ? <<END_OF_BLOCK : '';
<table border="0" width="100%" cellspacing="0" cellpadding="3">
-<tr><td class="_block" valign="middle">
-<big><strong><span class="block">&nbsp;$Title</span></strong></big>
+<tr><td class="_podblock_"$tdstyle valign="middle">
+<big><strong><span class="_podblock_">&nbsp;$Title</span></strong></big>
</td></tr>
</table>
END_OF_BLOCK
@@ -307,10 +311,17 @@ END_OF_BLOCK
<link rev="made" href="mailto:$Config{perladmin}" />
</head>
-<body>
+<body$bodystyle>
$block
HTMLHEAD
+ $parser->html_footer(<<"HTMLFOOT");
+$block
+</body>
+
+</html>
+HTMLFOOT
+
my $input;
unless (@ARGV && $ARGV[0]) {
if ($Podfile and $Podfile ne '-') {