summaryrefslogtreecommitdiff
path: root/inc/funktion_menu.php
diff options
context:
space:
mode:
Diffstat (limited to 'inc/funktion_menu.php')
-rwxr-xr-xinc/funktion_menu.php41
1 files changed, 41 insertions, 0 deletions
diff --git a/inc/funktion_menu.php b/inc/funktion_menu.php
new file mode 100755
index 00000000..e90e99b6
--- /dev/null
+++ b/inc/funktion_menu.php
@@ -0,0 +1,41 @@
+<?PHP
+
+function ShowMenu( $Menu )
+{
+ if( !isset($Menu["Entry"]) ) return;
+
+ global $MenueTableStart, $MenueTableEnd, $_SESSION, $DEBUG;
+
+ echo $MenueTableStart;
+ echo "<h4 class=\"menu\">". $Menu["Name"]. "</h4>";
+
+ foreach( $Menu["Entry"] as $Entry )
+ {
+ //wenn File mit ../ beginnt wird "../" abgeschnitten und der Ordener weggelassen
+ if( strstr( $Entry["File"], "../" ) != FALSE )
+ $MenuFile = substr( $Entry["File"], strpos( $Entry["File"], "../" )+ 3) ;
+ else
+ $MenuFile = $Menu["Path"]. $Entry["File"];
+
+ if( $_SESSION['CVS'][$MenuFile] == "Y")
+ echo "\t\t\t<li><a href=\"". $Entry["File"]. "\">". $Entry["Name"]. "</a></li>\n";
+
+ echo $Entry["Line"];
+
+
+ //DEBUG
+ if( $DEBUG )
+ {
+ if( !isset($_SESSION['CVS'][$MenuFile] ) )
+ echo "ERROR CVS: '". $MenuFile. "' not set";
+
+ if( $_SESSION['CVS'][$MenuFile] != "Y")
+ echo "\t\t\t<li>". $Entry["File"]. " (". $Entry["Name"]. ")</li>\n";
+ } // DEBUG
+ } //foreach
+
+ echo $MenueTableEnd;
+} //function ShowMenue
+
+
+?>