]> jfr.im git - irc/unrealircd/unrealircd-webpanel.git/blobdiff - common.php
Update overview
[irc/unrealircd/unrealircd-webpanel.git] / common.php
index cde08bd9bcda203c847d1cab89738878351fc741..e6df7da64a12ff3a502ebf2950539e53c330c27a 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 define('UPATH', dirname(__FILE__));
 require_once "config.php";
-if (!defined('BASE_DIR')) die("You need to define BASE_DIR in config.php (see config.php.sample for documentation)");
+if (!defined('BASE_URL')) die("You need to define BASE_URL in config.php (see config.php.sample for documentation)");
 require_once "Classes/class-hook.php";
 if (!is_dir(UPATH . "/vendor"))
        die("The vendor/ directory is missing. Most likely the admin forgot to run 'composer install'\n");
@@ -14,11 +14,20 @@ require_once "Classes/class-message.php";
 require_once "Classes/class-rpc.php";
 require_once "plugins.php";
 
-$pages = Array("Overview"      => "index.php",
-                          "Users"              => "users/index.php",
-                          "Channels"   => "channels.php",
-                          "Server Bans"        => "tkl.php",
+function show_nick_only($str)
+{
+       $x = strpos($str, "!");
+       if ($x !== false)
+               $str = substr($str, 0, $x);
+       return $str;
+}
+
+$pages = Array("Overview"      => "",
+                          "Users"              => "users",
+                          "Channels"   => "channels",
+                          "Server Bans"        => "server_bans.php",
                           "Spamfilter" => "spamfilter.php",
+                          "Network" => "network",
                           "News"               => "news.php");