Commit a113c178a5b5999ddb76c1cf9dab47629c57f05d

Authored by michael
1 parent 51a5b918

simple admin page


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@2516 c91229c3-7414-0410-bfa2-8a42b809f60b
presentation/lookAndFeel/knowledgeTree/administration/admin.php
@@ -18,9 +18,12 @@ require_once("$default->fileSystemRoot/presentation/Html.inc"); @@ -18,9 +18,12 @@ require_once("$default->fileSystemRoot/presentation/Html.inc");
18 * Display the heading for the admin section 18 * Display the heading for the admin section
19 */ 19 */
20 function renderAdminHeading($sHeading, $sSectionName = "") { 20 function renderAdminHeading($sHeading, $sSectionName = "") {
21 - $sCenter .= renderHeading("Administration"); 21 + global $default;
  22 +
  23 + $sAction = $default->siteMap->getActionFromPage(substr($_SERVER["PHP_SELF"], strlen($default->rootUrl), strlen($_SERVER["PHP_SELF"])));
  24 + $sCenter .= renderHeading($default->siteMap->getPageLinkText($sAction));
  25 +
22 $sCenter .= "<table width=\"600\">\n"; 26 $sCenter .= "<table width=\"600\">\n";
23 - $sCenter .= "<tr/><tr/><tr><td><b> Welcome to the Administration Section</b></td></tr>\n";  
24 $sCenter .= "<tr><td>Please make a selection from the sidemenu.</td></tr>\n"; 27 $sCenter .= "<tr><td>Please make a selection from the sidemenu.</td></tr>\n";
25 $sCenter .= "</table>\n"; 28 $sCenter .= "</table>\n";
26 return $sCenter; 29 return $sCenter;
@@ -28,12 +31,12 @@ function renderAdminHeading($sHeading, $sSectionName = &quot;&quot;) { @@ -28,12 +31,12 @@ function renderAdminHeading($sHeading, $sSectionName = &quot;&quot;) {
28 31
29 if (checkSession()) { 32 if (checkSession()) {
30 require_once("$default->fileSystemRoot/presentation/webpageTemplate.inc"); 33 require_once("$default->fileSystemRoot/presentation/webpageTemplate.inc");
31 - 34 +
32 if (!isset($sectionName)) { 35 if (!isset($sectionName)) {
33 $sectionName = "Administration"; 36 $sectionName = "Administration";
34 - } 37 + }
35 $sCenter .= "<table width=\"600\">\n"; 38 $sCenter .= "<table width=\"600\">\n";
36 - $sCenter .= renderAdminHeading("Administration"); 39 + $sCenter .= renderAdminHeading("Administration", $sectionName);
37 $sCenter .= "</table>\n"; 40 $sCenter .= "</table>\n";
38 41
39 $oPatternCustom = & new PatternCustom(); 42 $oPatternCustom = & new PatternCustom();