Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $result = $db->query('SELECT * FROM user WHERE username="'.$_SESSION["username"].'"');
- while($userinfos = $result->fetch_array(MYSQLI_ASSOC))
- {
- $adminrang = $userinfos["admin"];
- }
- if($_SESSION['adminrang'] > 2)
- {
- $adminPath = System_Dir."pages/admin/";
- if(isset($_GET['a']) && !empty($_GET['a']))
- {
- if(file_exists($adminPath.$_GET['a'].".php"))
- {
- include($adminPath.$_GET['a'].".php");
- }
- else {
- include($adminPath."index.php");
- }
- } else
- {
- include($adminPath."index.php");
- }
- }
- else
- {
- echo'<center><h2><p class="meldung">Sie sind nicht für diesen Bereich berechtigt.</p></h2></center>';
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement