diff --git a/e107_admin/cpage.php b/e107_admin/cpage.php index 7c1793ba3..dce7eec11 100644 --- a/e107_admin/cpage.php +++ b/e107_admin/cpage.php @@ -784,16 +784,15 @@ class page_admin_ui extends e_admin_ui $chap = intval($row['page_chapter']); - $this->tabs[] = "Additional Fields"; - - $curVal = e107::unserialize($row['page_fields']); - - $tabCount = count($this->tabs) -1; $this->getModel()->set('page_fields', null); if(!empty($this->chapterFields[$chap])) { + $curVal = e107::unserialize($row['page_fields']); + + $this->tabs[] = "Additional Fields"; + $tabCount = count($this->tabs) -1; foreach($this->chapterFields[$chap] as $key=>$fld) { diff --git a/e107_handlers/form_handler.php b/e107_handlers/form_handler.php index 76af9b5ab..cb4395981 100644 --- a/e107_handlers/form_handler.php +++ b/e107_handlers/form_handler.php @@ -5786,7 +5786,7 @@ e107::getDebug()->log($sc_parameters); $text .= " "; - $text .= (varset($writeParms['nolabel']) == 2) ? '' : "
".$leftCell."
" ; + $text .= (isset($writeParms['nolabel']) && $writeParms['nolabel'] == 2) ? '' : "
".$leftCell."
" ; $text .= $rightCell."