diff options
| author | sillylaird <sillyfanboy@gmail.com> | 2026-09-03 00:33:59 +0000 |
|---|---|---|
| committer | sillylaird <sillyfanboy@gmail.com> | 2026-09-03 00:33:59 +0000 |
| commit | 898b52edcb47bcb3e9d6106e74ca73e74ea01e70 (patch) | |
| tree | 85c6ee5ad58b860144551184d4cf86b560c62b91 /now | |
| download | www-898b52edcb47bcb3e9d6106e74ca73e74ea01e70.tar.gz www-898b52edcb47bcb3e9d6106e74ca73e74ea01e70.zip | |
Diffstat (limited to 'now')
| -rw-r--r-- | now/index.php | 65 | ||||
| -rw-r--r-- | now/now-data.php | 59 |
2 files changed, 124 insertions, 0 deletions
diff --git a/now/index.php b/now/index.php new file mode 100644 index 0000000..c780b74 --- /dev/null +++ b/now/index.php @@ -0,0 +1,65 @@ +<?php +$now_data = is_file(__DIR__ . '/now-data.php') ? (require __DIR__ . '/now-data.php') : ['updated' => '', 'sections' => []]; +$now_updated = $now_data['updated'] ?: date('Y-m-d'); +$now_sections = is_array($now_data['sections'] ?? null) ? $now_data['sections'] : []; +?> +<!doctype html> +<html lang="en"> +<head> + <meta charset="utf-8" /> + <meta name="viewport" content="width=device-width,initial-scale=1" /> + <title>Now — SillyLaird</title> + +<?php + $meta = [ + 'lang' => 'en', + 'title' => 'Now — SillyLaird', + 'desc' => 'What SillyLaird is up to right now.', + 'base' => 'now/index', + 'self_url' => 'https://www.sillylaird.ca/now/', + 'en_url' => 'https://www.sillylaird.ca/now/', + 'ja_url' => 'https://www.sillylaird.ca/now/', + 'zh_url' => 'https://www.sillylaird.ca/now/', + 'x_default' => 'https://www.sillylaird.ca/now/', + ]; + include __DIR__ . '/../partials/head_meta.php'; +?> + + + + <link rel="stylesheet" href="/assets/css/fonts.css" /> + <link rel="stylesheet" href="/assets/css/site.css" /> + <link rel="stylesheet" href="/assets/css/skeleton.css" /> +</head> + +<body> + <a class="skip-link" href="#main">Skip to content</a> + + <?php include '../partials/header.php'; ?> + + <main id="main" class="wrap"> + <section aria-labelledby="now-title"> + <h1 id="now-title">Now</h1> + <p class="muted">What I'm up to — updated <?= htmlspecialchars($now_updated, ENT_QUOTES, 'UTF-8') ?>. Inspired by <a href="https://nownownow.com/about" target="_blank" rel="noopener noreferrer">nownownow.com</a>.</p> + </section> + + <?php foreach ($now_sections as $i => $sec): + $title = (string)($sec['title'] ?? ''); + $items = is_array($sec['items'] ?? null) ? $sec['items'] : []; + if ($title === '' || $items === []) continue; + $slug = preg_replace('/[^a-z0-9]+/', '-', strtolower($title)) ?: 'section-' . $i; + ?> + <section aria-labelledby="<?= htmlspecialchars($slug, ENT_QUOTES, 'UTF-8') ?>-title"> + <h2 id="<?= htmlspecialchars($slug, ENT_QUOTES, 'UTF-8') ?>-title"><?= htmlspecialchars($title, ENT_QUOTES, 'UTF-8') ?></h2> + <ul class="contact-list"> + <?php foreach ($items as $item): ?> + <li><?= htmlspecialchars((string)$item, ENT_QUOTES, 'UTF-8') ?></li> + <?php endforeach; ?> + </ul> + </section> + <?php endforeach; ?> + </main> + + <?php include '../partials/footer.php'; ?> +</body> +</html> diff --git a/now/now-data.php b/now/now-data.php new file mode 100644 index 0000000..6229c1c --- /dev/null +++ b/now/now-data.php @@ -0,0 +1,59 @@ +<?php +// now-data.php — /now/ page content, edited via /admin.php +// Do not edit manually unless you know what you're doing. +if (realpath(__FILE__) === realpath($_SERVER['SCRIPT_FILENAME'] ?? '')) { http_response_code(404); exit; } + +return array ( + 'updated' => '2026-07-19', + 'sections' => + array ( + 0 => + array ( + 'title' => 'Building', + 'items' => + array ( + 0 => 'Keeping this page, the changelog, and guestbook feeling current', + 1 => 'Small-web bridges: Gemini capsule, Gopher hole, Tor & I2P mirrors', + 2 => 'Tuning an Emacs workflow and documenting the little computer fixes that stick', + ), + ), + 1 => + array ( + 'title' => 'Playing & practising', + 'items' => + array ( + 0 => 'WoW Classic and Hearthstone Battlegrounds', + 1 => 'Rhythm games — pop\'n music, GITADORA / DTXMania, and StepMania', + 2 => 'Slow-burn retro sessions, including Super Scope experiments', + ), + ), + 2 => + array ( + 'title' => 'Watching', + 'items' => + array ( + 0 => 'Baseball — NPB, CFL, CEBL, OSL, and PLL', + 1 => 'NLL and Ottawa teams when the season is on', + 2 => 'Older anime and VHS-era dubs when the mood hits', + ), + ), + 3 => + array ( + 'title' => 'Listening', + 'items' => + array ( + 0 => 'Last.fm scrobbles — see the homepage widget for what\'s on rotation', + 1 => 'radio.sillylaird.ca when I want a station instead of a playlist', + ), + ), + 4 => + array ( + 'title' => 'Computing', + 'items' => + array ( + 0 => '9front experiments on the ThinkPad and wherever else it will boot', + 1 => 'Desktop quality-of-life tweaks: trackball remaps, Windhawk, and Deskflow input sharing', + ), + ), + ), +); |
