WorldRadios documentation

Laravel radio directory · Now Playing · Android & iPhone app · VIP subscriptions

1 · Fresh install with the web installer

  1. In your hosting panel create a MySQL database and a user with all privileges on it.
  2. Upload the contents of the upload folder.
    • Best: point your domain's document root at the public folder.
    • cPanel where the root must stay public_html: upload everything into public_html. The included .htaccess sends every request into public/, so .env, storage and vendor can never be opened from a browser.
  3. Choose PHP 8.3 or newer for the domain (cPanel → MultiPHP Manager / Select PHP Version).
  4. Open your domain. You are taken to /install: the installer checks the server, then asks for the database details, your site address, and the admin username and password.
  5. Press Install. The tables are created and the starter content is loaded (untick “Load the 1,800+ starter stations” for an empty directory).
  6. Sign in at /radio_admin and set your name, logo, colours and e-mail under Theme & Settings.
Folders that must be writable: storage/, bootstrap/cache/ and public/assets/uploads/ (755 or 775).

Alternative: import the SQL file

Import sql/worldradios.sql into your database with phpMyAdmin, then run the web installer as above with the same database — it sees the existing tables, keeps them, and only creates your admin account.

From the command line

cp .env.example .env && php artisan key:generate
# put the database details into .env, then
php artisan worldradios:install            # --no-stations for an empty directory
php artisan worldradios:admin yourname 'a-strong-password' --email=you@example.com

2 · Upgrade from the previous (plain PHP) version

  1. Back up the database and the old assets/uploads folder.
  2. Upload the new files as above, and copy your old assets/uploads/* into public/assets/uploads/.
  3. Run the installer with your existing database. Only what is missing is added (song history, Google Play tables, new columns). Stations, owners, submissions and settings stay as they are.
  4. Upgrading this Laravel version later: upload the new files over the old ones (keep .env and public/assets/uploads). The first visit afterwards clears the old cached pages and adds any new database columns by itself; the Clear cache button in the admin panel does the same by hand.
  5. Old addresses keep working: radio.php?slug=… and the other .php pages redirect permanently to the new clean URLs, and the published app's api/app.php answers at the same address.
The old “premium code” system is removed in this version, because selling unlock codes outside Google Play is not allowed for Play Store apps. Ad-free access is now sold as VIP through Google Play and the App Store. The old Kotlin Android app is replaced by the Flutter app in mobile/ (same package name, so it updates the published app).

3 · Cron (optional)

Once an hour, either of these:

php /home/USER/site/artisan schedule:run
wget -qO- "https://yourdomain.com/radio_admin/cron.php?key=YOUR_KEY"

Each run does a little at a time, so the server never feels it:

The key and the settings are under Admin → Import Stations → Automatic schedule.

4 · Demo mode

Set APP_DEMO=true in .env to run a public demo: every admin and owner screen opens, but nothing is saved (song detection and the stream tester still work).

5 · Troubleshooting

Blank page or “500”Check that PHP is 8.3+ and that storage/ and bootstrap/cache/ are writable. Errors are written to storage/logs/.
Old admin screens still show, or a new page says 404Old cached copies are being used. Press the broom (Clear cache) at the top of the admin panel, or open /radio_admin once — the first visit after an upgrade clears them by itself.
Every page shows 404mod_rewrite is off, or the domain points at the wrong folder. Point it at public/, or keep the root .htaccess.
Installer cannot connectOn cPanel the database name and user carry your account prefix, e.g. cpuser_radio. The host is usually localhost.
No song titlesYour host must allow outgoing connections to the stream ports (often 8000/8080). Use Admin → Now Playing → Test a stream to see exactly what happens.