# Radio Free Elsewhere ## Project Overview Radio Free Elsewhere is an Internet radio station streaming eclectic music (Celtic folk, ambient/space, surf rock, and more). It runs on Icecast hosted on a Yunohost server. Streams are live and occasional — a few times per week in the evenings, typically around 7:30pm Eastern, running roughly two hours. This is not a 24/7 automated station. The shows have distinct themes and identities: - **O'Morain's Pub** — Celtic folk - **Cosmoeuphoria** — ambient and space music - **Bisexual Surfers From the Twilight of Time** — surf rock and rockabilly - **The Bollocks** - punk rock - **The Spin** - eclectic tunes from all genres ## Scope This repo covers the **frontend only** — the public-facing website. Icecast configuration, Yunohost server administration, and streaming software are out of scope. Do not look for or suggest changes to server-side streaming config. ## Key Files - [index.php](index.php) — Main page. Contains the audio player, now-playing widget, upcoming schedule section, and about section. Show information is updated here manually before each broadcast. - [now_playing.php](now_playing.php) — Fetches the currently playing track from the Icecast JSON status API and returns it as HTML. Called by the frontend every 15 seconds via `setInterval`. - [live.php](live.php) — Page for active broadcasts. Player on the left, recently played list on the right; the header background and heading change with the current show. - [recently_played.php](recently_played.php) — Returns the current broadcast's track history as table rows for `live.php`. - [includes/icecast.php](includes/icecast.php) — Shared Icecast fetching/parsing, album art lookup and Last.fm link helpers. - [includes/db.php](includes/db.php) — `getDB()` returns a shared PDO connection (session time zone UTC). - [includes/broadcasts.php](includes/broadcasts.php) — Broadcast lifecycle and track history logic. - [cli/poll_icecast.php](cli/poll_icecast.php) — Cron-run poller that records broadcasts and tracks. - [cli/set_show.php](cli/set_show.php) — Sets which show is airing next (or now). - [cli/create_admin.php](cli/create_admin.php) — Creates an admin account or resets its password. - [admin/](admin/) — Admin backend. Every page calls `requireAdmin()` from [includes/auth.php](includes/auth.php) and uses `adminHeader()`/`adminFooter()` from [includes/admin_layout.php](includes/admin_layout.php). ## Architecture - **Backend:** PHP only. No Composer, no package manager, no build step. - **Frontend:** HTML5 UP Strata template with custom CSS additions. No npm, no webpack, no preprocessor — edit CSS directly in `assets/css/main.css` or inline `