diff --git a/themes/marvin/marvin.css b/themes/marvin/marvin.css index 2671aee28ff1ccc3b65fb78b349bd803aaf090da..cd41f5809c30ac4383c54c167c01877231c4778b 100644 --- a/themes/marvin/marvin.css +++ b/themes/marvin/marvin.css @@ -16,7 +16,9 @@ h2 { h3, h4, h5, h6 { font-size: 1em; } - +table { + width: 100%; +} p { margin: 0 0 1em 0; padding: 0; diff --git a/themes/marvin/marvin.theme b/themes/marvin/marvin.theme index 6226e4f115541444542d1524cfe69d5c9df9818f..fdeefb118b87ef690b02450d5b6a611954b8cc0d 100644 --- a/themes/marvin/marvin.theme +++ b/themes/marvin/marvin.theme @@ -15,41 +15,47 @@ function marvin_help($section) { } function marvin_header($title = "") { - ?> - - - - - - <?php - if ($title) { - print $title ." - ". variable_get("site_name", "drupal"); - } - else { - print variable_get("site_name", "drupal") . ($slogan = variable_get("site_slogan", "")) ? " - $slogan" : ""; - } - ?> - - - - > - - - - - - - - - - \n"; + $output .= " \n"; + $output .= "
 
- -
- \n"; + $output .= "\n"; + $output .= "\n"; + $output .= theme_head($main); + $output .= ""; + + if ($title) { + $output .= $title ." - ". variable_get("site_name", "drupal"); + } + else { + $output .= variable_get("site_name", "drupal") . ($slogan = variable_get("site_slogan", "")) ? " - $slogan" : ""; + } + + $output .= "\n"; + $output .= "\n"; + $output .= "\n"; + $output .= "\n"; + + $output .= "\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= "
\"\" 
". theme("links", link_page()) ."
\n"; + + $output .= "\n"; + $output .= " \n"; + + $blocks = render_blocks("left"); + if ($blocks) { + $output .= " \n"; + } + $output .= "
\n"; + $output .= $blocks; + $output .= " \n"; + + return $output; } function marvin_node($node, $main = 0) { @@ -62,92 +68,101 @@ function marvin_node($node, $main = 0) { } $path = path_to_theme(); - print "\n\n"; - print "\n"; - print " \"\"   $node->title\n"; - print " \n"; - print " "; + $output = "\n\n"; + $output .= "
\"\"
". t("Submitted by %a on %b", array("%a" => format_name($node), "%b" => format_date($node->created, "large"))) ."
\n"; + $output .= " \"\"   $node->title\n"; + $output .= " \n"; + $output .= " "; if ($colspan) { - print ""; + $output .= ""; } - print " \n"; - print "  \n"; + $output .= " \n"; + $output .= "  \n"; if ($main && $node->teaser) { - print "

$node->teaser

\n"; + $output .= "

$node->teaser

\n"; } else { - print "

$node->body

\n"; + $output .= "

$node->body

\n"; } - print "  \n"; + $output .= "  \n"; if ($links = link_node($node, $main)) { - print " ". theme("links", $links) ."\n"; + $output .= " ". theme("links", $links) ."\n"; } - print "
\"\"
". t("Submitted by %a on %b", array("%a" => format_name($node), "%b" => format_date($node->created, "large"))) ."
". theme("links", $terms) ."". theme("links", $terms) ."
\n"; - print "

\n\n"; + $output .= "
\n"; + $output .= "

\n\n"; + return $output; } function marvin_comment($comment, $link = "") { // Create comment header: - print "\n"; - print " \n"; - print " \n"; + $output .= "
\n"; - print " \n"; - print " \n"; - print " \n"; - print " \n"; - print "
\n"; - print " \n"; - print " \n"; + $output = "
\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; // Print body of comment: if ($comment->comment) { - print " \n"; + $output .= " \n"; } // Print bottom link(s): - print " \n"; - print "
\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; - print " \n"; + $output .= "
\n"; + $output .= " \n"; + $output .= " \n"; // Subject: - print " \n"; - print " \n"; + $output .= " \n"; + $output .= " \n"; - print " \n"; + $output .= " \n"; // Author: - print " \n"; - print " \n"; - print " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; // Date - print " \n"; - print " \n"; - print " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; - print "
". t("Subject") .":
$comment->subject
". t("Subject") .":
$comment->subject
". t("Author") .":". format_name($comment) ."
". t("Author") .":". format_name($comment) ."
". t("Date") .":". format_date($comment->timestamp) ."
". t("Date") .":". format_date($comment->timestamp) ."
\n"; - print "
\n"; + $output .= "
$comment->comment
$comment->comment
[ $link ]
\n"; - print "
\n"; - print "
\n\n"; + $output .= "
[ $link ]
\n"; + $output .= "
\n"; + $output .= "
\n\n"; + + return $output; +} + +function marvin_block($block) { + return theme("box", $block->subject, $block->content); } function marvin_box($subject, $content, $region = "main") { - print "\n\n"; - print "\n"; - print " \n"; - print " \n"; - print " \n"; - print "
\n"; - print " \n"; - print " \n"; - print " \n"; - print "
$subject
$content
\n"; - print "
\n"; - print "
\n\n"; + $output = "\n\n"; + $output .= "\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= "
\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= "
$subject
$content
\n"; + $output .= "
\n"; + $output .= "
\n\n"; + + return $output; } function marvin_links($links, $delimiter = " · ") { @@ -155,25 +170,24 @@ function marvin_links($links, $delimiter = " · ") { } function marvin_footer() { - ?> - - - - - - - - ". theme("links", link_page()) ."

". variable_get("site_footer", "") ."

\n"; - ?> - - - - - - - \n"; + $blocks = render_blocks("right"); + if ($blocks) { + $output .= " \n"; + $output .= $blocks; + $output .= " \n"; + } + $output .= " \n"; + $output .= "\n"; + $output .= " \n"; + $output .= " \n"; + $output .= " \n"; + $output .= "
"; + $output .= "

". theme("links", link_page()) ."

". variable_get("site_footer", "") ."

\n"; + $output .= "
\n"; + $output .= theme_closure(); + $output .= "\n\n"; + + return $output; } ?>