diff --git a/get_online_session_communities.php b/get_online_session_communities.php
index b93ec17..3b652d1 100644
--- a/get_online_session_communities.php
+++ b/get_online_session_communities.php
@@ -582,14 +582,14 @@
}
}
- // test if active_users is valid
$active_users = $content["active_users"];
+ // test if active_users is valid
/*if($active_users == -1) {
$active_users = "N/A"; // this breaks sortTable()
}*/
$line =
- "
" . PHP_EOL .
+ "
" . PHP_EOL .
" " . $id . " | " . PHP_EOL .
" " . $content["name"] . " | " . PHP_EOL .
" " . $content["description"] . " | " . PHP_EOL .
@@ -650,7 +650,7 @@
" " . PHP_EOL .
" " . $title . "" . PHP_EOL .
" " . PHP_EOL .
- " " . PHP_EOL;
+ " " . PHP_EOL;
$post =
" " . PHP_EOL .
"" . PHP_EOL;
diff --git a/output/script.js b/output/script.js
index 6a57551..3033990 100644
--- a/output/script.js
+++ b/output/script.js
@@ -1,3 +1,33 @@
+function onLoad(timestamp) {
+ setLastChecked(timestamp);
+ hideBadCommunities();
+ sortTable(1); // 1 == Name
+}
+
+function hideBadCommunities() {
+ const testCommunityIDs = [
+ "2e9345+c7fb", // TestRoom
+ "762ba9+c7fb", // TesterRoom
+ "b4d829+c7fb", // Test
+ "e5853a+c7fb", // testtest
+ "test+118d", // Testing 1, 2, 3
+ "test+13f6", // Testing room
+ "test+fe93" // 测试(Test)
+ ];
+
+ const badCommunityIDs = [
+ "60fa60+c7fb" // "N-word" Community
+ ];
+
+ testCommunityIDs.forEach(hideElementByID);
+ badCommunityIDs.forEach(hideElementByID);
+}
+
+function hideElementByID(id) {
+ element = document.getElementById(id);
+ element.style.display = "none";
+}
+
function copyToClipboard(text) {
navigator.clipboard.writeText(text);
}
diff --git a/output/styles.css b/output/styles.css
index 986ef93..2532ba0 100644
--- a/output/styles.css
+++ b/output/styles.css
@@ -2,6 +2,8 @@
#tbl_communities { width:100%; }
+th { background-color: lightgray; }
+
#th_identifier { width:9%; }
.td_identifier { font-family: monospace; }
#th_name { width:13%; }