From: hickert Date: Tue, 30 May 2006 06:34:28 +0000 (+0000) Subject: Added check for available plugins X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=188aa8bc6ea499cb4d62e17a7ce3dbda1b4fb91c;p=gosa.git Added check for available plugins git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3553 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/include/class_pluglist.inc b/include/class_pluglist.inc index d4d017d1b..42f729db8 100644 --- a/include/class_pluglist.inc +++ b/include/class_pluglist.inc @@ -120,10 +120,17 @@ class pluglist { $plHeadline= $vars['plHeadline']; $plDescription= $vars['plDescription']; + $index= $this->get_index($info['PATH']); $image= get_template_path('images/'.$info['ICON']); $href= "main.php?plug=$index&reset=1"; + if(!$vars){ + $plHeadline = _("Unknown"); + $plDescription = _("Unknown"); + $href= "main.php?reset=1"; + } + if ($this->check_access($info['ACL'])){ $entries= $entries."

get_index($info['PATH']); + $href = "main.php?plug=".$index."&reset=1"; + + /* Check if class is available. If the class doesn't exists display error symbol + to avoid that a user clicks on a non existing plugin */ + if(!$vars){ + $plHeadline = $plDescription = _("Unknown"); + $info['ICON'] = "error.png"; + $href="main.php?reset=1"; + } + + if ($this->check_access($info['ACL'])){ /* Hm this looks doubled */ @@ -222,8 +240,8 @@ class pluglist { $entries= $entries.""; $col = 1; } - $entries= $entries."". + $entries= $entries."". "\"*\" ". _($plHeadline)."\n";