diff options
author | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-01-16 07:42:36 +0000 |
---|---|---|
committer | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-01-16 07:42:36 +0000 |
commit | 965afffeb50044f266975570bafe887ccea5b9f3 (patch) | |
tree | 967acb63f7e98a3e02ce5d532e597e9f58bf10fc /albums.php | |
parent | 883a1d60d3993f606131108d8c5675617d94bc82 (diff) | |
download | ampache-965afffeb50044f266975570bafe887ccea5b9f3.tar.gz ampache-965afffeb50044f266975570bafe887ccea5b9f3.tar.bz2 ampache-965afffeb50044f266975570bafe887ccea5b9f3.zip |
few more tweaks to box and index page
Diffstat (limited to 'albums.php')
-rw-r--r-- | albums.php | 25 |
1 files changed, 14 insertions, 11 deletions
@@ -91,6 +91,8 @@ switch ($action) { // get the Album information $album = new Album($_REQUEST['album_id']); + $images = array(); + $cover_url = array(); // If we've got an upload ignore the rest and just insert it if (!empty($_FILES['file']['tmp_name'])) { @@ -138,20 +140,21 @@ switch ($action) { } $images = array_merge($cover_url,$images); - // We don't want to store raw's in here so we need to strip them out into a seperate array - foreach ($images as $index=>$image) { - if (isset($image['raw'])) { - //unset($images[$index]); - $images[$index]['raw'] = ''; - } - } - - // Store the results for further use - $_SESSION['form']['images'] = $images; - + // If we've found anything then go for it! if (count($images)) { + // We don't want to store raw's in here so we need to strip them out into a seperate array + foreach ($images as $index=>$image) { + if (isset($image['raw'])) { + //unset($images[$index]); + $images[$index]['raw'] = ''; + } + } // end foreach + + // Store the results for further use + $_SESSION['form']['images'] = $images; require_once(conf('prefix') . '/templates/show_album_art.inc.php'); } + // Else nothing else { show_confirmation(_('Album Art Not Located'),_('Album Art could not be located at this time. This may be due to write access error, or the file is not received corectly.'),"/albums.php?action=show&album=" . $album->id); } |