Commit ef873561 authored by Dries's avatar Dries

- Improvements: XHTML-ifications.  Patch by GmbH.  See feature #1813.
parent e5f2c1ef
......@@ -24,7 +24,7 @@ function header($title = "") {
$output = "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"DTD/xhtml1-transitional.dtd\">\n";
$output .= "<html><head><title>". $title ? $title : variable_get(site_name, "drupal") ."</title>";
$output .= theme_head($main);
$output .= "</head><body bgcolor=\"$this->background\" text=\"$this->foreground". theme_onload_attribute(). "\">";
$output .= "</head><body style=\"background-color: $this->background; color: $this->foreground;\"". theme_onload_attribute(). "\">";
$output .= "<table border=\"0\" cellspacing=\"4\" cellpadding=\"4\"><tr><td style=\"vertical-align: top; width: 170px;\">";
print $output;
......
......@@ -735,7 +735,7 @@ function import_page_blocks($blocks) {
theme("header");
theme("box", t("News feeds"), import_page_info());
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" width=\"100%\">\n";
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" style=\"width: 100%;\">\n";
print " <tr>\n";
for ($t = 0; $t < 3; $t++) {
......
......@@ -735,7 +735,7 @@ function import_page_blocks($blocks) {
theme("header");
theme("box", t("News feeds"), import_page_info());
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" width=\"100%\">\n";
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" style=\"width: 100%;\">\n";
print " <tr>\n";
for ($t = 0; $t < 3; $t++) {
......
......@@ -172,7 +172,7 @@ function block_admin_preview() {
while ($block = db_fetch_object($result)) {
$block_data = module_invoke($block->module, "block", "list");
$name = $block_data[$block->delta]["info"];
$rblocks .= " <tr><td nowrap=\"nowrap\">". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
$rblocks .= " <tr><td>". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
}
$rblocks .= "</table>\n";
......@@ -188,7 +188,7 @@ function block_admin_preview() {
while ($block = db_fetch_object($result)) {
$block_data = module_invoke($block->module, "block", "list");
$name = $block_data[$block->delta]["info"];
$blocks .= " <tr><td nowrap=\"nowrap\">". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
$blocks .= " <tr><td>". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
}
$blocks .= "</table>\n";
......
......@@ -172,7 +172,7 @@ function block_admin_preview() {
while ($block = db_fetch_object($result)) {
$block_data = module_invoke($block->module, "block", "list");
$name = $block_data[$block->delta]["info"];
$rblocks .= " <tr><td nowrap=\"nowrap\">". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
$rblocks .= " <tr><td>". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
}
$rblocks .= "</table>\n";
......@@ -188,7 +188,7 @@ function block_admin_preview() {
while ($block = db_fetch_object($result)) {
$block_data = module_invoke($block->module, "block", "list");
$name = $block_data[$block->delta]["info"];
$blocks .= " <tr><td nowrap=\"nowrap\">". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
$blocks .= " <tr><td>". ($block->status == 2 ? "<b>$name</b>" : $name) ."</td><td>$block->weight</td></tr>\n";
}
$blocks .= "</table>\n";
......
......@@ -1293,7 +1293,7 @@ function comment_thread_max($comment, $threshold, $level = 0) {
*/
if ($level) {
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td style=\"width: ". ($level * 25) ."px;\">&nbsp;</td><td>\n";
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"width: 100%;\"><tr><td style=\"width: ". ($level * 25) ."px;\">&nbsp;</td><td>\n";
}
comment_view($comment, comment_links($comment, 0), comment_visible($comment, $threshold));
......
......@@ -1293,7 +1293,7 @@ function comment_thread_max($comment, $threshold, $level = 0) {
*/
if ($level) {
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td style=\"width: ". ($level * 25) ."px;\">&nbsp;</td><td>\n";
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"width: 100%;\"><tr><td style=\"width: ". ($level * 25) ."px;\">&nbsp;</td><td>\n";
}
comment_view($comment, comment_links($comment, 0), comment_visible($comment, $threshold));
......
......@@ -735,7 +735,7 @@ function import_page_blocks($blocks) {
theme("header");
theme("box", t("News feeds"), import_page_info());
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" width=\"100%\">\n";
print "<table cellpadding=\"0\" cellspacing=\"5\" border=\"0\" style=\"width: 100%;\">\n";
print " <tr>\n";
for ($t = 0; $t < 3; $t++) {
......
......@@ -752,7 +752,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
}
if ($displaycount = variable_get("statistics_userpage_day_cnt", 10)) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("daycount", $displaycount);
$output .= "</table>";
......@@ -761,7 +761,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
if ($displaycount = variable_get("statistics_userpage_all_cnt", "10")) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("totalcount", $displaycount);
$output .= "</table>";
......@@ -769,7 +769,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
}
if ($displaycount = variable_get("statistics_userpage_last_cnt", "10")) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("timestamp", $displaycount);
$output .= "</table>";
......
......@@ -752,7 +752,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
}
if ($displaycount = variable_get("statistics_userpage_day_cnt", 10)) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("daycount", $displaycount);
$output .= "</table>";
......@@ -761,7 +761,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
if ($displaycount = variable_get("statistics_userpage_all_cnt", "10")) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("totalcount", $displaycount);
$output .= "</table>";
......@@ -769,7 +769,7 @@ function statistics_page_user($uid = 0, $date = 0, $all = 0) {
}
if ($displaycount = variable_get("statistics_userpage_last_cnt", "10")) {
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" width=\"100%\">";
$output = "<table border=\"0\" cellpadding=\"4\" cellspacing=\"4\" style=\"width: 100%;\">";
$output .= statistics_summary("timestamp", $displaycount);
$output .= "</table>";
......
......@@ -57,7 +57,7 @@ function watchdog_overview($type) {
while ($watchdog = db_fetch_object($result)) {
if ($background = $color[$watchdog->type]) {
$data .= " <tr bgcolor=\"$background\"><td>". format_date($watchdog->timestamp, "small") ."</td><td>". substr(strip_tags($watchdog->message), 0, 64) ."</td><td style=\"text-align: center;\">". format_name($watchdog) ."</td><td style=\"text-align: center;\">$watchdog->link</td><td style=\"text-align: center;\">". l(t("view details"), "admin/watchdog/view/$watchdog->wid") ."</td></tr>";
$data .= " <tr style=\"background-color: $background\"><td>". format_date($watchdog->timestamp, "small") ."</td><td>". substr(strip_tags($watchdog->message), 0, 64) ."</td><td style=\"text-align: center;\">". format_name($watchdog) ."</td><td style=\"text-align: center;\">$watchdog->link</td><td style=\"text-align: center;\">". l(t("view details"), "admin/watchdog/view/$watchdog->wid") ."</td></tr>";
}
}
......
......@@ -57,7 +57,7 @@ function watchdog_overview($type) {
while ($watchdog = db_fetch_object($result)) {
if ($background = $color[$watchdog->type]) {
$data .= " <tr bgcolor=\"$background\"><td>". format_date($watchdog->timestamp, "small") ."</td><td>". substr(strip_tags($watchdog->message), 0, 64) ."</td><td style=\"text-align: center;\">". format_name($watchdog) ."</td><td style=\"text-align: center;\">$watchdog->link</td><td style=\"text-align: center;\">". l(t("view details"), "admin/watchdog/view/$watchdog->wid") ."</td></tr>";
$data .= " <tr style=\"background-color: $background\"><td>". format_date($watchdog->timestamp, "small") ."</td><td>". substr(strip_tags($watchdog->message), 0, 64) ."</td><td style=\"text-align: center;\">". format_name($watchdog) ."</td><td style=\"text-align: center;\">$watchdog->link</td><td style=\"text-align: center;\">". l(t("view details"), "admin/watchdog/view/$watchdog->wid") ."</td></tr>";
}
}
......
......@@ -14,6 +14,7 @@ h2 {
h3, h4, h5, h6 {
font-size: 1em;
}
p {
margin: 0 0 1em 0;
padding: 0;
......@@ -24,8 +25,27 @@ img {
table {
font-size: 1em;
}
.calendar .day-today { background-color: #ccc; }
.calendar .day-selected { background-color: #bbb; }
.calendar .header-month { background-color: #ddd; }
.calendar .header-week { background-color: #ccc; }
.calendar .day-blank { background-color: #ddd; }
.calendar .day-today {
background-color: #ccc;
}
.calendar .day-selected {
background-color: #bbb;
}
.calendar .header-month {
background-color: #ddd;
}
.calendar .header-week {
background-color: #ccc;
}
.calendar .day-blank {
background-color: #ddd;
}
a:link {
color: #656
}
a:visited {
color: #656
}
a:active {
color: #ccc
}
......@@ -6,7 +6,7 @@ class Theme_marvin extends BaseTheme {
// General colorset that can be used for this theme
var $foreground = "#000000";
var $background = "#EAEAEA";
var $background = "#eaeaea";
function system($field) {
$system["name"] = "Marvin";
......@@ -36,10 +36,10 @@ function header($title = "") {
@import "themes/marvin/marvin.css";
</style>
</head>
<body text="#000000" bgcolor="#ffffff" alink="#cccccc" link="#665566" vlink="#665566"<?php print theme_onload_attribute(); ?>>
<body<?php print theme_onload_attribute(); ?>>
<table border="0" cellpadding="8" cellspacing="0">
<tr>
<td><a href="index.php"><img src="<?php print $this->path; ?>/images/logo.png" alt="" border="0" /></a></td>
<td><a href="index.php"><img src="<?php print $this->path; ?>/images/logo.png" style="border: 0px;" alt="" title="" /></a></td>
<td>&nbsp;</td>
</tr>
<tr>
......@@ -64,9 +64,9 @@ function node($node, $main = 0) {
print "\n<!-- node: \"$node->title\" -->\n";
print "<table cellpadding=\"0\" cellspacing=\"0\" style=\"border 0px; width: 100%;\">\n";
print " <tr><td colspan=\"2\"><img src=\"$this->path/images/drop.gif\" alt=\"\" /> &nbsp; <b>$node->title</b></td></tr>\n";
print " <tr valign=\"bottom\"><td colspan=\"2\" bgcolor=\"#000000\" width=\"100%\"><img src=\"$this->path/images/pixel.gif\" width=\"1\" height=\"1\" alt=\"\" /></td></tr>\n";
print " <tr><td nowrap=\"nowrap\"><font color=\"#7C7C7C\"><small>". t("Submitted by %a on %b", array("%a" => format_name($node), "%b" => format_date($node->created, "large"))); ?><?php print "</small></font></td><td align=\"right\" valign=\"top\" nowrap=\"nowrap\"><small>". $this->links($terms) ."</small></td></tr>\n";
print " <tr><td colspan=\"2\"><img src=\"$this->path/images/drop.gif\" alt=\"\" title=\"\" /> &nbsp; <b>$node->title</b></td></tr>\n";
print " <tr style=\"vertical-align: bottom;\"><td colspan=\"2\" style=\"background-color: #000000; width: 100%;\"><img src=\"$this->path/images/pixel.gif\" width=\"1\" height=\"1\" alt=\"\" title=\"\" /></td></tr>\n";
print " <tr><td><div style=\"color: #7c7c7c;\"><small>". t("Submitted by %a on %b", array("%a" => format_name($node), "%b" => format_date($node->created, "large"))); ?><?php print "</small></div></td><td style=\"text-align: right; vertical-align: top;\"><small>". $this->links($terms) ."</small></td></tr>\n";
print " <tr><td colspan=\"2\">&nbsp;</td></tr>\n";
if ($main && $node->teaser) {
......@@ -88,29 +88,29 @@ function node($node, $main = 0) {
function comment($comment, $link = "") {
// Create comment header:
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#000000\" width=\"100%\">\n";
print " <tr bgcolor=\"#000000\">\n";
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"background-color: #000000; width: 100%;\">\n";
print " <tr style=\"background-color: #000000;\">\n";
print " <td>\n";
print " <table border=\"0\" cellpadding=\"3\" cellspacing=\"1\" width=\"100%\">\n";
print " <table border=\"0\" cellpadding=\"3\" cellspacing=\"1\" style=\"width: 100%;\">\n";
print " <tr>\n";
print " <td bgcolor=\"#eaeaea\">\n";
print " <table border=\"0\" cellpadding=\"2\" cellspacing=\"1\" width=\"100%\">\n";
print " <td style=\"background-color: #eaeaea;\">\n";
print " <table border=\"0\" cellpadding=\"2\" cellspacing=\"1\" style=\"width: 100%;\">\n";
print " <tr>\n";
// Subject:
print " <td align=\"right\" width=\"5%\"><b>". t("Subject") .":</b></td>\n";
print " <td width=\"80%\"><b><font color=\"#666699\">$comment->subject</font></b></td>\n";
print " <td style=\"text-align: right; width: 5%;\"><b>". t("Subject") .":</b></td>\n";
print " <td style=\"width: 80%;\"><b><div style=\"color: #666699;\">$comment->subject</div></b></td>\n";
print " </tr>\n";
// Author:
print " <tr>\n";
print " <td align=\"right\" valign=\"top\">". t("Author") .":</td><td>". format_name($comment) ."</td>\n";
print " <td style=\"text-align: right; vertical-align: top;\">". t("Author") .":</td><td>". format_name($comment) ."</td>\n";
print " </tr>\n";
// Date
print " <tr>\n";
print " <td align=\"right\">". t("Date") .":</td><td>". format_date($comment->timestamp) ."</td>\n";
print " <td style=\"text-align: right;\">". t("Date") .":</td><td>". format_date($comment->timestamp) ."</td>\n";
print " </tr>\n";
print " </table>\n";
......@@ -119,11 +119,11 @@ function comment($comment, $link = "") {
// Print body of comment:
if ($comment->comment) {
print " <tr><td bgcolor=\"#FFFFFF\">$comment->comment</td></tr>\n";
print " <tr><td style=\"background-color: #ffffff;\">$comment->comment</td></tr>\n";
}
// Print bottom link(s):
print " <tr><td align=\"right\" bgcolor=\"#EAEAEA\">[ $link ]</td></tr>\n";
print " <tr><td style=\"background-color: #eaeaea; text-align: right;\">[ $link ]</td></tr>\n";
print " </table>\n";
print " </td>\n";
print " </tr>\n";
......@@ -133,12 +133,12 @@ function comment($comment, $link = "") {
function box($subject, $content, $region = "main") {
print "\n<!-- box: \"$subject\" -->\n";
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#000000\" width=\"100%\">\n";
print "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" style=\"background-color: #000000; width: 100%;\">\n";
print " <tr>\n";
print " <td>\n";
print " <table border=\"0\" cellpadding=\"5\" cellspacing=\"1\" width=\"100%\">\n";
print " <tr><td align=\"center\" bgcolor=\"#eaeaea\"><font color=\"#404040\"><b>$subject</b></font></td></tr>\n";
print " <tr><td bgcolor=\"#ffffff\" valign=\"top\">$content</td></tr>\n";
print " <table border=\"0\" cellpadding=\"5\" cellspacing=\"1\" style=\"width: 100%;\">\n";
print " <tr><td style=\"background-color: #eaeaea; text-align: center;\"><div style=\"color: #404040;\"><b>$subject</b></div></td></tr>\n";
print " <tr><td style=\"background-color: #ffffff; vertical-align: top;\">$content</td></tr>\n";
print " </table>\n";
print " </td>\n";
print " </tr>\n";
......@@ -153,14 +153,14 @@ function links($links, $delimiter = " &middot; ") {
function footer() {
?>
</td>
<td valign="top" width="200">
<td style="width: 200px; vertical-align: top;">
<?php
theme_blocks("all", $this);
?>
</td>
</tr>
<tr>
<td align="center" colspan="2">
<td colspan="2" style="text-align: center;">
<?php
print "<p><small>". $this->links(link_page()) ."</small></p><p>". variable_get("site_footer", "") ."</p>\n";
?>
......
......@@ -15,8 +15,8 @@
<table border="0" cellpadding="0" cellspacing="0" class="header">
<tr>
<td class="menu" valign="bottom"><a href="./"><img src="themes/xtemplate/images/druplicon.gif" alt="" /></a></td>
<td class="menu" align="right" valign="middle">
<td class="menu" style="vertical-align: bottom;"><a href="./"><img src="themes/xtemplate/images/druplicon.gif" alt="" title="" /></a></td>
<td class="menu" style="text-align: right; vertical-align: middle;">
<div id="secondary">{secondary_links}</div>
<div id="primary">{primary_links}</div>
<!-- BEGIN: search_box -->
......@@ -33,7 +33,7 @@
<table border="0" cellpadding="0" cellspacing="0" class="header">
<tr>
<!-- BEGIN: blocks -->
<td valign="top" id="sidebar-left">
<td id="sidebar-left" style="vertical-align: top;">
{blocks}
</td>
<!-- END: blocks -->
......@@ -91,7 +91,7 @@
</div><!-- main -->
</td>
<!-- BEGIN: blocks -->
<td valign="top" id="sidebar-right">
<td id="sidebar-right" style="vertical-align: top;">
{blocks}
</td>
<!-- END: blocks -->
......
......@@ -769,11 +769,11 @@ function update_sql($sql) {
print nl2br(htmlentities($sql)) ." ";
$result = db_query($sql);
if ($result) {
print "<font color=\"green\">OK</font>\n";
print "<div style=\"color: green;\">OK</div>\n";
return 1;
}
else {
print "<font color=\"red\">FAILED</font>\n";
print "<div style=\"color: red;\">FAILED</div>\n";
if ($edit["bail"]) {
die("Fatal error. Bailing");
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment