Fixed some notices on some custom pages

This commit is contained in:
moodler 2007-08-31 03:45:59 +00:00
parent a84902827e
commit 3a1ac34002
2 changed files with 5 additions and 5 deletions

View File

@ -7195,10 +7195,10 @@ function setup_lang_from_browser() {
////////////////////////////////////////////////////////////////////////////////
function is_newnav($navigation) {
if (is_array($navigation) && $navigation['newnav']) {
return(true);
if (is_array($navigation) && !empty($navigation['newnav'])) {
return true;
} else {
return(false);
return false;
}
}

View File

@ -3383,11 +3383,11 @@ function build_navigation($extranavlinks) {
if ($i > 0) {
$navigation .= get_separator();
}
if ($navlink['link'] && $i+1 < $countlinks) {
if ((!empty($navlink['link'])) && $i+1 < $countlinks) {
$navigation .= "<a onclick=\"this.target='$CFG->framename'\" href=\"{$navlink['link']}\">";
}
$navigation .= "{$navlink['name']}";
if ($navlink['link'] && $i+1 < $countlinks) {
if ((!empty($navlink['link'])) && $i+1 < $countlinks) {
$navigation .= "</a>";
}