some fixes

This commit is contained in:
biglyderv 2025-02-23 01:52:53 -05:00
parent 66300ccd71
commit 08fe66906c
Signed by: biglyderv
GPG key ID: 1398543B9746192C
3 changed files with 40 additions and 58 deletions

View file

@ -14,50 +14,51 @@ function page_header()
$posts2 = $stmt->fetchAll(PDO::FETCH_DEFAULT);
$edge = count($posts2);
?>
<!DOCTYPE html>
<html>
<head>
<title>BiglyChat</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1">
<link rel="icon" href="/img/bgc.svg">
<link rel="stylesheet" href="/css/main.css">
</head>
<body>
<div class="header">
<a href="/"><img class="header-img header-link" src="/img/bgc.svg">BiglyChat</a>
<?php if (isset($username)) { ?>
<a href="/user.php?id=<?php echo $username ?>"><img class="header-img header-link" src="/pfp/<?php echo $username ?>.png">Wall</a>
<a href="/notif.php"> <img class="header-img header-link" src="/img/mail.svg"><span>Mail<sub> <?php echo $edge?></sub></span></a>
<a href="/stats.php?username=<?php echo $username ?>"><img class="header-img header-link" src="/img/home.svg">Users</a>
<a href="/logout.php" class='leave'><img class="header-img header-link" src="/img/logout.svg">Leave</a>
<?php } else { ?>
<a href="/login.php"><img class="header-img header-link" src="/img/home.svg">Join</a>
<a href="/stats.php"><img class="header-img header-link" src="/img/home.svg">Users</a>
<?php }
?>
</div>
<?php }
<!DOCTYPE html>
<html>
<head>
<title>BiglyChat</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1">
<link rel="icon" href="/img/bgc.svg">
<link rel="stylesheet" href="/css/main.css">
</head>
<body>
<div class="header">
<a href="/index.php"><img class="header-img header-link" src="/img/bgc.svg">BiglyChat</a>
<?php if (isset($username)) { ?>
<a href="/index.php?mode=followers"><img class="header-img header-link" src="/img/bgc.svg">Feed</a>
<a href="/user.php?id=<?php echo $username ?>"><img class="header-img header-link" src="/pfp/<?php echo $username ?>.png">Wall</a>
<a href="/stats.php?username=<?php echo $username ?>"><img class="header-img header-link" src="/img/home.svg">Users</a>
<a href="/notif.php"> <img class="header-img header-link" src="/img/mail.svg"><span>Mail<sub> <?php echo $edge?></sub></span></a>
<a href="/logout.php" class='leave'><img class="header-img header-link" src="/img/logout.svg">Leave</a>
<?php } else { ?>
<a href="/login.php"><img class="header-img header-link" src="/img/home.svg">Join</a>
<a href="/stats.php"><img class="header-img header-link" src="/img/home.svg">Users</a>
<?php } ?>
</div>
<?php
}
function page_footer()
{ ?>
{
?>
</body>
</html>
<?php }
<?php }
function user_block($usern, $meta, $tag)
{
?>
<div class='comment'>
<div class="avatar">
<div class='comment'>
<div class="avatar">
<img src="/pfp/<?php echo $usern ?>.png" class="avatar-img">
<div>
<div><b>
<a class="link" href="/user.php?id=<?php echo $usern ?>">
<?php echo $usern ?>
</a>
</b>
<b>
<a class="link" href="/user.php?id=<?php echo $usern ?>">
<?php echo $usern ?>
</a>
</b>
</div>
</div>
</div>
<?php echo (is_null($meta) || !$meta) ? '' : "<b>$tag</b>: $meta"; ?>
</div>
<?php }
</div>
<?php echo (is_null($meta) || !$meta) ? '' : "<b>$tag</b>: $meta"; ?>
</div>
<?php }
?>