Actualizar 'index.php'
This commit is contained in:
parent
3242f3b927
commit
b7b7787a1d
56
index.php
56
index.php
|
@ -30,6 +30,7 @@
|
|||
}
|
||||
img.av{width:70px;height:70px;}
|
||||
a{color:#00FF08;}
|
||||
.nick{font-size:large;font-weight:bold;}
|
||||
footer{margin:5% 0 0 0;}
|
||||
</style>
|
||||
</head>
|
||||
|
@ -38,23 +39,44 @@
|
|||
<h1>Luqaska's S**te</h1>
|
||||
<?php
|
||||
if(isset($_GET["book"])){
|
||||
echo "\t<p>To be here, create a file at <code>~/.lucas</code>. The content of that file will be displayed down your name.</p>\n\t<p>Inspired by <a href=\"https://tilde.team/~mwt/\">~mwt</a>'s one.</p>";
|
||||
echo "\t<p>To be here, create a file at <code style='background:#00FF08;color:black;font-weight:bold'>~/.lucas</code>. The content of that file will be displayed adove your username.</p>\n\t<p>Inspired by <a href=\"https://tilde.team/~mwt/\">~mwt</a>'s one.</p>";
|
||||
echo "\t<table>";
|
||||
foreach(glob("/home/*") as $user){
|
||||
echo "\t<table>";
|
||||
if(file_exists($user."/.lucas")){ $nick=str_replace("/home/","",$user);?>
|
||||
<tr>
|
||||
<td><?php if(file_exists($user."/public_html/avatar.png")){
|
||||
echo '<img class="av" src="https://ttm.sh/~'.$nick.'/avatar.png">';
|
||||
}else{
|
||||
echo '<img class="av" src="https://ttm.sh/ege.png" style="image-rendering:pixelated">';
|
||||
<td><?php if (file_exists($user."/public_html/avatar.png")) {
|
||||
echo '<img class="av" src="//ttm.sh/~'.$nick.'/avatar.png">';
|
||||
} else {
|
||||
echo '<img class="av" src="//ttm.sh/ege.png" style="image-rendering:pixelated">';
|
||||
} ?></td>
|
||||
<td>
|
||||
<h2><a href="https://tilde.team/<?= $nick ?>/">~<?= $nick ?></a></h2>
|
||||
<p><?= htmlentities(file_get_contents($user."/.lucas")) ?></p>
|
||||
</td>
|
||||
<td><p>
|
||||
<?php
|
||||
$msg = htmlentities(file_get_contents($user."/.lucas"));
|
||||
if ($msg == "") {
|
||||
$msg = "";
|
||||
} else {
|
||||
$msg = explode(" ", $msg);
|
||||
foreach($msg as $num => $message) {
|
||||
if ($message == "") {
|
||||
unset($msg[$num]);
|
||||
}
|
||||
}
|
||||
$msg = implode(" ", $msg);
|
||||
$msg = explode("\n", $msg);
|
||||
foreach($msg as $num => $line) {
|
||||
if ($line == "") {
|
||||
unset($msg[$num]);
|
||||
}
|
||||
}
|
||||
$msg = implode("\n", $msg);
|
||||
$msg = preg_replace("/\n/", "<br>", $msg);
|
||||
$msg = "\t\t\t\t\t\"" . $msg . '"<br>';
|
||||
} echo $msg; ?>
|
||||
<a class="nick" href="https://tilde.team/<?= $nick ?>/">~<?= $nick ?></a>
|
||||
</p></td>
|
||||
<?php }
|
||||
echo "\t</table>";
|
||||
}
|
||||
echo "\t</table>";
|
||||
}else{
|
||||
?>
|
||||
|
||||
|
@ -62,23 +84,23 @@ foreach(glob("/home/*") as $user){
|
|||
<h2>/t/ools</h2>
|
||||
<?php show_dir("t") ?>
|
||||
</div>
|
||||
<div id="tetld">
|
||||
<!--<div id="tetld">
|
||||
<h2>/tetld/</h2>
|
||||
<?php show_dir("tetld") ?>
|
||||
</div>
|
||||
</div>-->
|
||||
<div id="etc">
|
||||
<h2>Etc.</h2>
|
||||
<ul>
|
||||
<li><a href="filde/">Filde</a></li>
|
||||
<li>Visits: <a href="https://tilde.club/~harper/counter.html">
|
||||
<!--<li>Visits: <a href="https://tilde.club/~harper/counter.html">
|
||||
<img width="50px" height="auto" style="background:white" src="https://tilde-counter.firebaseapp.com/counter/">
|
||||
</a></li>
|
||||
</a></li>-->
|
||||
<li><a href="?book">Sign book</a></li>
|
||||
</ul>
|
||||
<div id="linkz">
|
||||
<h2>Linkz</h2>
|
||||
<ul>
|
||||
<li><a href="gemini://tilde.team/~lucas/">Gemini version</a></li>
|
||||
<li><a href="gemini://tilde.team/~lucas/">Gemini</a></li>
|
||||
<li><a href="gopher://tilde.team/1/~lucas/">Gopher hole</a></li>
|
||||
<li><a href="https://tilde.team">~team</a></li>
|
||||
<li><a href="https://tilde.team/~lucas/twtxt/">TWTXT</a></li>
|
||||
|
@ -96,7 +118,7 @@ foreach(glob("/home/*") as $user){
|
|||
</div>
|
||||
<?php } ?>
|
||||
<footer><p style="text-align:left">
|
||||
©2021 Luqaska
|
||||
©2021-2022<span style="display:none"> - </span>
|
||||
<a style="float:right;text-decoration:none" href="https://tildegit.org/luqaska/website">Code</a>
|
||||
</p></footer>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue