add tagline feature
the first line of your ~/.ring file will be shown here as your tagline edit as you please :)
This commit is contained in:
parent
6de03525e5
commit
e9dd5e47e9
|
@ -54,12 +54,18 @@ else {
|
|||
<p>then create a .ring file in your ~ to be added in the webring:</p>
|
||||
<pre>$ touch ~/.ring</pre>
|
||||
|
||||
<h3>explore webring</h3>
|
||||
<p>the first line of ~/.ring will be displayed here as a tagline</p>
|
||||
|
||||
<h3 id="explore">explore webring</h3>
|
||||
<p><a href="?action=random">jump to random page</a></p>
|
||||
<p>all members:</p>
|
||||
<ul>
|
||||
<?php foreach ($users as $user): ?>
|
||||
<li><a href="https://tilde.team/~<?=$user?>/">~<?=$user?></a></li>
|
||||
<?php foreach ($users as $user):
|
||||
if (filesize("/home/$user/.ring") > 0)
|
||||
$tagline = htmlspecialchars(trim(fgets(fopen("/home/$user/.ring", "r"))));
|
||||
else unset($tagline); ?>
|
||||
|
||||
<li><a href="https://tilde.team/~<?=$user?>/">~<?=$user?></a><?=(isset($tagline) ? " — " : "")?><?=$tagline ?? ""?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
|
||||
|
|
Loading…
Reference in New Issue