mirror of https://github.com/tildeclub/site.git
Updated homepage indicator, reduced html output
This commit is contained in:
parent
dd62a18333
commit
81eeb53987
|
@ -212,7 +212,7 @@ if (isset($_GET['notice'])) {
|
||||||
// Cache not available or expired
|
// Cache not available or expired
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$homepages_list = '<ul class="user-list">';
|
$homepages_list = '<div class="user-list">';
|
||||||
|
|
||||||
foreach (glob("/home/*") as $user) {
|
foreach (glob("/home/*") as $user) {
|
||||||
// Look for index files with common extensions
|
// Look for index files with common extensions
|
||||||
|
@ -232,12 +232,11 @@ if (isset($_GET['notice'])) {
|
||||||
}
|
}
|
||||||
|
|
||||||
$user = basename($user);
|
$user = basename($user);
|
||||||
$class = $recentChange ? 'recently-updated' : '';
|
|
||||||
|
|
||||||
$homepages_list .= '<li class="'.$class.'"><a href="/~'.$user.'/">~'.$user.'</a></li>';
|
$homepages_list .= '<a href="/~'.$user.'/">'.(($recentChange) ? '<b>~'.$user.'</b>' : '~'.$user).'</a>';
|
||||||
}
|
}
|
||||||
|
|
||||||
$homepages_list .= '</ul>';
|
$homepages_list .= '</div>';
|
||||||
|
|
||||||
// Save cache file
|
// Save cache file
|
||||||
$save_cache = file_put_contents($cache_file, $homepages_list);
|
$save_cache = file_put_contents($cache_file, $homepages_list);
|
||||||
|
|
39
style.css
39
style.css
|
@ -17,23 +17,6 @@
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.user-list {
|
|
||||||
display: flex;
|
|
||||||
flex-flow: row wrap;
|
|
||||||
justify-content: space-evenly;
|
|
||||||
list-style-type: none;
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
.user-list li {
|
|
||||||
overflow: hidden;
|
|
||||||
text-overflow: ellipsis;
|
|
||||||
white-space: nowrap;
|
|
||||||
flex: 10em;
|
|
||||||
}
|
|
||||||
.user-list::after {
|
|
||||||
content: "";
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: auto;
|
margin: auto;
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
|
@ -140,6 +123,24 @@ code > span.fl {
|
||||||
padding-top: 5px;
|
padding-top: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.user-list {
|
||||||
|
display: flex;
|
||||||
|
flex-flow: row wrap;
|
||||||
|
justify-content: space-evenly;
|
||||||
|
list-style-type: none;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
.user-list a {
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
flex: 10em;
|
||||||
|
}
|
||||||
|
.user-list b {
|
||||||
|
background-color: #fb5;
|
||||||
|
color:#000;
|
||||||
|
}
|
||||||
|
|
||||||
input[type="text"],
|
input[type="text"],
|
||||||
textarea {
|
textarea {
|
||||||
background-color: #333;
|
background-color: #333;
|
||||||
|
@ -294,10 +295,6 @@ pre {
|
||||||
border-radius: 0.25em; /* Slight border radius for better appearance */
|
border-radius: 0.25em; /* Slight border radius for better appearance */
|
||||||
padding: 0.5em; /* Padding for better readability */
|
padding: 0.5em; /* Padding for better readability */
|
||||||
}
|
}
|
||||||
.recently-updated a {
|
|
||||||
font-weight: bold;
|
|
||||||
color: #fb5 !important; /* Use !important to override other styles */
|
|
||||||
}
|
|
||||||
|
|
||||||
#active-users {
|
#active-users {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
|
|
Loading…
Reference in New Issue