';
$headerNoButtons = '' . $sitename . '
';
$headerLoggedIn = '' . $sitename . '
';
$headerAdmin = '' . $sitename . '
';
$footer = '';
function printTag($tag, $largerFontSize = false) {
if($largerFontSize == false) {
echo '' . $tag . '';
} else {
echo '' . $tag . '';
}
}
function dispImage($imgurl, $tags) {
$imgstart = '';
$imgend = '
';
echo "$imgstart";
for($x = 0; $x < count($tags); $x++) {
printTag($tags[$x]);
}
echo "$imgend";
}
function showHeader($hideButtons = 0) {
// PHP is so quirky!!! I love scoping :sparkling-heart:
global $headerNoButtons;
global $headerLoggedIn;
global $headerGuest;
global $headerAdmin;
global $db;
if ($hideButtons == 1) { echo $headerNoButtons; return; }
if (!empty($db) && isset($_COOKIE["meowboardSession"])) {
if (isAdmin(tokenToUuid($_COOKIE["meowboardSession"])) == 1) {
echo $headerAdmin;
return;
} else {
echo $headerLoggedIn;
return;
}
}
if (isset($_COOKIE["meowboardSession"])) { echo $headerLoggedIn; return; }
echo $headerGuest;
}
?>