Skip to content
Snippets Groups Projects
Commit e28981f0 authored by Steven Wittens's avatar Steven Wittens
Browse files

- Updated BaseTheme and the Drupal themes to have header($title = "") as the...

- Updated BaseTheme and the Drupal themes to have header($title = "") as the header declaration and use title when provided. This is just a step towards having unique titles.
In all themes, except Marvin which already had $title, I put the $title first, because it's usually the thing the page is about:

"The future of weblogs? - Drop.org"
"Your account settings - Drop.org"

rather than the other way around, right?
parent ce6be094
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -3,7 +3,7 @@
class BaseTheme {
function header() {
function header($title = "") {
$output .= "<html><head><title>". variable_get(site_name, "drupal") ."</title></head><body>";
$output .= "<table border=\"0\" cellspacing=\"4\" cellpadding=\"4\"><tr><td valign=\"top\" width=\"170\">";
......
......@@ -17,12 +17,12 @@ class Theme extends BaseTheme {
var $foreground = "#000000";
var $background = "#FFFFFF";
function header() {
function header($title = "") {
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title><?php echo variable_get(site_name, "drupal"); ?></title>
<title><?php echo ($title ? ($title . " - ") : "") . variable_get(site_name, "drupal"); ?></title>
<style type="text/css">
<!--
body { background-color: #FFFFFF; font-size: 10pt; font-family: tahoma,helvetica,arial; }
......
......@@ -6,13 +6,13 @@ class Theme extends BaseTheme {
var $foreground = "#000000";
var $background = "#FFFFFF";
function header() {
function header($title = "") {
global $user;
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
<html>
<head>
<title><? echo variable_get(site_name, "drupal"); ?></title>
<title><? echo ($title ? ($title . " - ") : "") . variable_get(site_name, "drupal"); ?></title>
<style type="text/css">
<!--
body, td, p { margin: 10px; font-size: 12pt; font-family: Verdana, Helvetica; }
......
......@@ -37,12 +37,12 @@ class Theme extends BaseTheme {
var $bgcolor3 = "#D7D7D7";
var $fgcolor3 = "#000000";
function header() {
function header($title = "") {
srand((double)microtime()*1000000);
?>
<HTML>
<HEAD>
<TITLE><?php echo variable_get(site_name, "drupal"); ?></TITLE>
<TITLE><?php echo ($title ? ($title . " - ") : "") . variable_get(site_name, "drupal"); ?></TITLE>
<STYLE type="text/css">
<!--
TABLE { border-width: 0; }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment