more generic

This commit is contained in:
skeeter 2000-12-21 04:17:50 +00:00
parent 6c1f1d4de4
commit 84286356ea

View File

@ -13,21 +13,21 @@
{ {
echo "<p>\n"; echo "<p>\n";
$imgfile = $phpgw->common->get_image_dir("calendar")."/" . $appname .".gif"; $imgfile = $phpgw->common->get_image_dir($appname)."/" . $appname .".gif";
if (file_exists($imgfile)) { if (file_exists($imgfile)) {
$imgpath = $phpgw->common->get_image_path("calendar")."/" . $appname .".gif"; $imgpath = $phpgw->common->get_image_path($appname)."/" . $appname .".gif";
} else { } else {
$imgfile = $phpgw->common->get_image_dir("calendar")."/navbar.gif"; $imgfile = $phpgw->common->get_image_dir($appname)."/navbar.gif";
if (file_exists($imgfile)) { if (file_exists($imgfile)) {
$imgpath = $phpgw->common->get_image_path("calendar")."/navbar.gif"; $imgpath = $phpgw->common->get_image_path($appname)."/navbar.gif";
} else { } else {
$imgpath = ""; $imgpath = "";
} }
} }
section_start("Calendar",$imgpath); section_start(ucfirst($appname),$imgpath);
$pg = $phpgw->link($phpgw_info["server"]["webserver_url"]."/calendar/preferences.php"); $pg = $phpgw->link($phpgw_info["server"]["webserver_url"]."/".$appname."/preferences.php");
echo "<a href=".$pg.">" . lang("Calendar preferences") . "</a>"; echo "<a href=".$pg.">" . lang("Calendar preferences") . "</a>";
section_end(); section_end();