website/app/routes/music.php

14 lines
214 B
PHP
Executable File

<?php
$app->get('/music', function() use($app) {
$albums = $app->album->all();
$songs = $albums[0]->songs;
$app->render('music.twig', [
'albums' => $albums,
'songs' => $songs,
]);
})->name('music');