aboutsummaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorHannah Isopod <me@bathynomus.xyz>2025-06-11 03:25:00 -0600
committerHannah Isopod <me@bathynomus.xyz>2025-06-11 03:25:00 -0600
commitb3bb0b898d3178963fefb9c0b16a00a76cf2a034 (patch)
treeeec6da7a21790183b15f31283fe3b8bcaabfaa4d /index.php
parent5023bdef46281034c0476bc4201342a0a4cc2ae7 (diff)
total guestbook overhaul + new blog post + etc
- Added /about/pronouns/ in leiu of something like a pronouns.cc profile - New blog post about my new and improved AI opinions - Moved Stop Using Chromium to an actual blog post page - Blog posts now have previous and next buttons - New /blog/ background - Moved status.cafe widget from /blog/ to landing page - Total overhaul of guestbook: - Merged guestbook and blog comment section code - Beefed up bot protection - Added a word filter - Added a property to entries to facilitate holding comments for review and approving or denying them manually (The interface for this is somewhere else) - IP address from which a post originates is now tracked in order to IP ban malicious actors - Various new buttons - Updated /greenhouse/ - The site is now a member of the No AI Webring - a couple minor CSS fixes
Diffstat (limited to 'index.php')
-rw-r--r--index.php43
1 files changed, 40 insertions, 3 deletions
diff --git a/index.php b/index.php
index fdae17a..42b6ff1 100644
--- a/index.php
+++ b/index.php
@@ -41,13 +41,14 @@
margin-right: var(--stdpadding);
}
#bubblecolumn {
- position: absolute;
+ position: fixed;
right: 7%;
top: 0;
width: 29px;
height: 100%;
background-image: url(images/bubblecolumn1.gif);
background-repeat: repeat-y;
+ pointer-events: none;
}
#bucketfish, .bflink {
--red: #ffcaca;
@@ -137,6 +138,7 @@
}
</style>
<?php
+ include($_SERVER['DOCUMENT_ROOT'] . '/common.php');
include($_SERVER['DOCUMENT_ROOT'] . '/seasonal.php');
if(!preg_match('/(headless.*)/i', $_SERVER['HTTP_USER_AGENT'])) {
$captions = array();
@@ -254,6 +256,9 @@
'is this a bedbuge?',
'is this buge trans gener?',
'Now in HD!',
+ 'Hard Disk Drive!',
+ '"Tablet or smartphone device"',
+ 'Free Palestine!',
'COUNTER',
'TUEADAY',
'PLACEHIM',
@@ -274,9 +279,9 @@
if(!$seasonal) {
switch($cap) {
case 'COUNTER':
- $num = (int) filter_var(file_get_contents("views.txt"), FILTER_SANITIZE_NUMBER_INT);
+ $num = (int) filter_var(file_get_contents($datadir."caption_views.txt"), FILTER_SANITIZE_NUMBER_INT);
$num++;
- file_put_contents("views.txt", $num);
+ file_put_contents($datadir."caption_views.txt", $num);
$cap = "This caption has been viewed $num times!";
$tit = "This title has been viewed $num times!";
break;
@@ -333,6 +338,28 @@
<h1 style="margin-top: 0;">isopod dot cool<sup>v3.1</sup></h1>
<h2 id="caption"><?php echo $cap; ?></h2>
</div>
+ <?php
+ $username = "niceopod"; // Your username here!
+ $ch = curl_init("https://status.cafe/users/$username/status.json");
+
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
+ curl_setopt($ch, CURLOPT_HEADER, 0);
+
+ $str = curl_exec($ch);
+ if(curl_error($ch)) {
+ //echo curl_error($ch);
+ $str = "";
+ }
+ curl_close($ch);
+ $status_data = json_decode($str, true);
+ $status_content = $status_data["content"];
+ $face = $status_data["face"];
+ $timeago = $status_data["timeAgo"];
+ if(strlen($status_content) < 1) {
+ $status_content = "Something's gone wrong server side...";
+ }
+ echo "<figure class='quote'><blockquote id='statuscafe'><div id='statuscafe-username'><a href='https://status.cafe/users/$username' target='_blank'>status</a> $face $timeago</div><div id='statuscafe-content'>$status_content</div></blockquote></figure>";
+ ?>
<nav id="webrings">
<div style="font-family: sans-serif; font-weight: bold;">
<a href="https://hotlinewebring.club/bathynomus/previous" style="color: white; text-decoration: none;">←</a>
@@ -354,7 +381,17 @@
<a href="https://fediring.net/random">?</a>
<a href="https://fediring.net/next?host=isopod.cool">→</a>
</div>
+ <div>
+ <a href="https://baccyflap.com/noai/?prv&s=ipd">←</a>
+ <a href="https://baccyflap.com/noai">no AI webring</a>
+ <a href="https://baccyflap.com/noai/?rnd">?</a>
+ <a href="https://baccyflap.com/noai/?nxt&s=ipd">→</a>
+ </div>
</nav>
+ <div class="buttons">
+ <img src="etc/buttons/isopodhours.png" alt="isopod hours">
+ <a target="_blank" href="https://deeptwisty.com/"><img src="etc/buttons/deeptwisty_button.png" alt="deep twisty"></a>
+ </div>
<!--script type="text/javascript">document.write('<a href="desktop.html">$login<span class="blinking" >_</span></a>');</script-->
</main>