diff --git a/inc/page.php b/inc/page.php
index 03ac195..2a972b1 100644
--- a/inc/page.php
+++ b/inc/page.php
@@ -524,6 +524,9 @@ class Page {
$this->table_headers_printed = true;
}
$id = $row['id'];
+ if ($this->settings->info_show_random_id) {
+ $id = $this->obscureID->obscure($id);
+ }
echo "
";
foreach ($array as $header => $text) {
$a = "a";
diff --git a/inc/settings.php b/inc/settings.php
index c5c25a2..e73f4f3 100644
--- a/inc/settings.php
+++ b/inc/settings.php
@@ -34,16 +34,20 @@ class Settings {
// (Note: this feature requires LiteBans version 2.16.2 or later.)
$this->random_secret = '';
+
// Show server scope column?
$this->show_server_scope = false;
// Show server origin column?
$this->show_server_origin = false;
- // Show server scope column in info.php?
+ // Show random ID on info.php?
+ $this->info_show_random_id = false;
+
+ // Show server scope column on info.php?
$this->info_show_server_scope = false;
- // Show server origin column in info.php?
+ // Show server origin column on info.php?
$this->info_show_server_origin = true;
// Show inactive bans? Removed bans will show (Unbanned), mutes will show (Unmuted), warnings will show (Expired).
diff --git a/info.php b/info.php
index a5d5958..7eaeb65 100644
--- a/info.php
+++ b/info.php
@@ -157,6 +157,10 @@ $page->set_info($page->type_info($type));
filter_var($id, FILTER_VALIDATE_INT) or die("Invalid ID");
$id = (int)$id;
+$displayID = $id;
+if ($page->settings->info_show_random_id) {
+ $displayID = $page->obscureID->obscure($id);
+}
// Safe user input (constants only)
$type = $page->type;
@@ -180,7 +184,7 @@ if ($st->execute()) {
$name = $page->t("generic.$type");
$permanent = $info->permanent();
- $page->name = $page->title = "$name #$id";
+ $page->name = $page->title = "$name #$displayID";
$page->print_title();
$header = $page->name;