Skip to content
Permalink
Browse files

Fixed PHP Fatal and Warnings for "farm" environment (thanks @cultcom #…

  • Loading branch information...
LotarProject committed Jul 10, 2019
1 parent 9688da8 commit 869d9a2b1e406415c991c0e7ce4169ded8f2bced
Showing with 17 additions and 6 deletions.
  1. +13 −4 Template.php
  2. +4 −2 tpl/page-tools.php
@@ -2257,11 +2257,20 @@ public function normalizeContent($content)
$plugin_name = $matches[1];
$extension = plugin_load('helper', 'extension_extension');
$extension->setExtension($plugin_name);
if ($extension = plugin_load('helper', 'extension_extension')) {
foreach ($elm->find('legend') as $legend) {
$legend->innertext = '<i class="mdi mdi-puzzle text-success"></i> '. $legend->innertext .' <br/><h6>'. $extension->getDescription() .' <a class="urlextern" href="'. $extension->getURL() .'" target="_blank">Docs</a></h6>';
if ($extension->setExtension($plugin_name)) {
foreach ($elm->find('legend') as $legend) {
$legend->innertext = '<i class="mdi mdi-puzzle text-success"></i> '. $legend->innertext .' <br/><h6>'. $extension->getDescription() .' <a class="urlextern" href="'. $extension->getURL() .'" target="_blank">Docs</a></h6>';
}
}
} else {
foreach ($elm->find('legend') as $legend) {
$legend->innertext = '<i class="mdi mdi-puzzle text-success"></i> '. $legend->innertext;
}
}
}
@@ -23,8 +23,10 @@
$page_menu = $TEMPLATE->getToolMenu('page');
foreach ($page_menu['menu'] as $type => $item) {
echo $item['html'];
if (isset($page_menu['menu'])) {
foreach ($page_menu['menu'] as $type => $item) {
echo $item['html'];
}
}
?>

0 comments on commit 869d9a2

Please sign in to comment.
You can’t perform that action at this time.