summaryrefslogtreecommitdiff
path: root/includes/fragments/member.inc
diff options
context:
space:
mode:
authorRaindropsSys <contact@minteck.org>2023-03-21 16:21:21 +0100
committerRaindropsSys <contact@minteck.org>2023-03-21 16:21:21 +0100
commit475c5731bf3362b6ac8d2dc5d5b43e4b4a6117bd (patch)
tree2cff46debf9c1e13892e7babff9deb6874ecb4b2 /includes/fragments/member.inc
parent7ccc2de87f9e25c715dc09b9aba4eb5c66f80424 (diff)
downloadpluralconnect-475c5731bf3362b6ac8d2dc5d5b43e4b4a6117bd.tar.gz
pluralconnect-475c5731bf3362b6ac8d2dc5d5b43e4b4a6117bd.tar.bz2
pluralconnect-475c5731bf3362b6ac8d2dc5d5b43e4b4a6117bd.zip
Updated 26 files and added 1074 files (automated)
Diffstat (limited to 'includes/fragments/member.inc')
-rw-r--r--includes/fragments/member.inc22
1 files changed, 21 insertions, 1 deletions
diff --git a/includes/fragments/member.inc b/includes/fragments/member.inc
index bbdfc98..1d9530c 100644
--- a/includes/fragments/member.inc
+++ b/includes/fragments/member.inc
@@ -48,6 +48,11 @@ if ($memberData["name"] === "fusion") {
window.onscroll = () => {
document.getElementById("member-banner-container").style.height = (<?= !isset($memberData["banner"]) ? "33" : "65" ?> - ((window.scrollY / window.screen.availHeight) * 100)) + "vh";
}
+
+ function showPrivate() {
+ document.getElementById("private-page-link").style.display = "none";
+ document.getElementById("private-page-hidden").style.display = "block";
+ }
</script>
<br>
@@ -84,7 +89,22 @@ if ($memberData["name"] === "fusion") {
<?php else: ?>
<?php if (file_exists($_SERVER['DOCUMENT_ROOT'] . "/includes/data/content/$memberID-private.html") && $isLoggedIn): ?>
<br>
- <?= file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/content/$memberID-private.html") ?>
+ <?php
+
+ $text = file_get_contents($_SERVER['DOCUMENT_ROOT'] . "/includes/data/content/$memberID-private.html");
+ $censor = false;
+
+ if (str_contains(strtolower($text), "sex") || str_contains(strtolower($text), "nsfw") || str_contains(strtolower($text), "pleasure") || str_contains(strtolower($text), "dildo") || str_contains(strtolower($text), "dick") || str_contains(strtolower($text), "penis") || str_contains(strtolower($text), "vagina") || str_contains(strtolower($text), "pussy")) {
+ $censor = true;
+ }
+
+ if ($censor) {
+ echo("<a href='#' id='private-page-link' onclick='showPrivate();'>Show private page (NSFW)</a><div id='private-page-hidden' style='display: none;'>" . $text . "</div>");
+ } else {
+ echo($text);
+ }
+
+ ?>
<?php if (file_exists($_SERVER['DOCUMENT_ROOT'] . "/includes/data/content/$memberID.html")): ?><hr><?php endif; ?>
<?php endif; ?>