Initial commit

This commit is contained in:
Kwesi Banson Jnr
2026-04-08 05:53:02 +00:00
commit 592a161ee6
63 changed files with 4105 additions and 0 deletions

View File

@@ -0,0 +1,27 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title><?= $title ?? 'My PHP App' ?></title>
<link rel="stylesheet" href="/css/style.css">
</head>
<body>
<nav>
<a href="/">Home</a>
<?php if (\App\Core\Auth::check()): ?>
<span>Welcome, <?= htmlspecialchars(\App\Core\Auth::user()) ?></span>
<a href="/logout">Logout</a>
<?php else: ?>
<a href="/login">Login</a>
<?php endif; ?>
</nav>
<main>
<!-- This is where the page content goes -->
<?= $content ?>
</main>
<footer>&copy; <?= date('Y') ?> My Vanilla App</footer>
<script src="/js/app.js"></script>
</body>
</html>

View File

@@ -0,0 +1,8 @@
<!-- The $title and $users variables were passed from the controller -->
<h1><?= htmlspecialchars($title) ?></h1>
<ul>
<?php foreach ($users as $user): ?>
<li><?= htmlspecialchars($user['name']) ?> (<?= htmlspecialchars($user['email']) ?>)</li>
<?php endforeach; ?>
</ul>