<?php // require("../includes/config.php"); $pms = get_inbox(); render_mult(["user_common.php", "inbox.php"], ["title" => $u["username"] . "'s Inbox", "pg" => "user.php?u=" . $u["username"], "self" => $self, "u" => $u, "pms" => $pms]);
} if ($error->copied) { echo "Track " . $error->file . " <strong>copied</strong></br>"; } else { echo "Track " . $error->file . " <strong>copy failed</strong></br>"; } } } } } /************************************ List Files in inbox and inbox/albums/..name.. directories ************************************/ echo '<form action="' . $_SERVER['PHP_SELF'] . '" method="POST">'; $inbox = json_decode(get_inbox()); // get inbox directories and files from rest-webservice as json if ($_GET["level0"] == "albums") { // scan album dirs (albums) and list files if ($inbox->albums->length > 0) { echo "<h4> Choose Albums to import: </h4>"; for ($j = 0; $j < $inbox->albums->length; $j++) { if ($inbox->albums->{$j}->length > 0) { echo "<strong>" . htmlspecialchars($inbox->albums->{$j}->name) . "</strong> ("; echo htmlspecialchars($inbox->albums->{$j}->dir) . "): "; echo '<input type="checkbox" name="album_' . $j . '" value="' . htmlspecialchars($inbox->albums->{$j}->dir) . '" /></br>'; echo "\n"; echo '<input type="hidden" name="album_' . $j . '_name" value="' . htmlspecialchars($inbox->albums->{$j}->name) . '" />'; echo "\n"; for ($i = 0; $i < $inbox->albums->{$j}->length; $i++) { echo '<input type="hidden" name="album_' . $j . '_file_' . $i . '" value="' . htmlspecialchars($inbox->albums->{$j}->tracks[$i]) . '" />';