Hide empty breadcrumb

This commit is contained in:
Jakub Vrana 2011-03-15 18:35:24 +01:00
parent 8e5d9d0756
commit f60058aa74

View file

@ -35,10 +35,9 @@ function page_header($title, $error = "", $breadcrumb = array(), $title2 = "") {
<div id="content">
<?php
}
echo '<p id="breadcrumb">';
if (isset($breadcrumb)) {
$link = substr(preg_replace('~(username|db|ns)=[^&]*&~', '', ME), 0, -1);
echo '<a href="' . ($link ? h($link) : ".") . '">' . $drivers[DRIVER] . '</a> &raquo; ';
echo '<p id="breadcrumb"><a href="' . ($link ? h($link) : ".") . '">' . $drivers[DRIVER] . '</a> &raquo; ';
$link = substr(preg_replace('~(db|ns)=[^&]*&~', '', ME), 0, -1);
$server = (SERVER != "" ? h(SERVER) : lang('Server'));
if ($breadcrumb === false) {