Handle null title properly

This commit is contained in:
ruan 2016-02-21 06:48:13 +02:00
parent c9bc532c82
commit 7cb40db874

View File

@ -271,8 +271,12 @@ class Page {
function print_title() { function print_title() {
$title = $this->title; $title = $this->title;
$name = $this->settings->name; $name = $this->settings->name;
if ($title === null) {
echo "<title>$name</title>";
} else {
echo "<title>$title - $name</title>"; echo "<title>$title - $name</title>";
} }
}
function print_table_rows($row, $array, $print_headers = true) { function print_table_rows($row, $array, $print_headers = true) {
if ($print_headers && !$this->table_headers_printed) { if ($print_headers && !$this->table_headers_printed) {