deedc3e35d94c0d716ccb63996c7d4cafd95267d
bernd webinterface => /webinterface

bernd authored 17 years ago

1) <?php
2) 
bernd Menü-Includes sinnvoller /...

bernd authored 16 years ago

3) $menu = array();
4) 
bernd webinterface => /webinterface

bernd authored 17 years ago

5) $role = $_SESSION['role'];
6) 
7) switch ($role)
8) {
9)   case ROLE_ANONYMOUS:
10)     $menu["index_login"] = array("label" => "Login", "file" => "index.php", "weight" => 0);
11)     break;
12)   default:
13)     $menu["index_logout"] = array("label" => "Logout", "file" => "logout.php", "weight" => 99);
14)     $menu["index_chpass"] = array("label" => "Passwort ändern", "file" => "chpass.php", "weight" => 98);
15)     $menu["index_index"] = array("label" => "Übersicht", "file" => "index.php", "weight" => 0);
16)     
17) }
18) 
bernd Menü-Includes sinnvoller /...

bernd authored 16 years ago

19) if (empty($menu))
20)   $menu = false;
21) 
22)