summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorTheTroll <trolldev@gmail.com>2010-03-27 13:14:23 +0100
committerTheTroll <trolldev@gmail.com>2010-03-27 13:14:23 +0100
commit1c756d4357f3be6ff8dd97f7a74e2c04f99726a6 (patch)
treed3a7d149c7d7c330bfca55381d765a0b97107481 /bin
parent1237d5c0aacc7082d8fb7eca1c52f4c0edb0ddd0 (diff)
downloadistreamdev-1c756d4357f3be6ff8dd97f7a74e2c04f99726a6.tar.gz
istreamdev-1c756d4357f3be6ff8dd97f7a74e2c04f99726a6.tar.bz2
Prepared for nice rec name
Diffstat (limited to 'bin')
-rwxr-xr-xbin/files.php23
1 files changed, 14 insertions, 9 deletions
diff --git a/bin/files.php b/bin/files.php
index 123644e..6060fa9 100755
--- a/bin/files.php
+++ b/bin/files.php
@@ -206,18 +206,23 @@ function filesgetlisting($dir)
list($newentry['trackname'], $newentry['length']) = mediagetmusicinfo($dir ."/" .$value);
$newentry['number'] = $number;
$number++;
+ $filelisting[] = $newentry;
+ break;
case 'video':
+ $filelisting[] = $newentry;
+ break;
case 'folder':
+ $newentry['path'] = $newentry['path'] .'/';
+ // Skip emtpy dirs
+ if (glob(quotemeta($newentry['path']) .'*'))
+ $folderlisting[] = $newentry;
+ break;
case 'rec':
- if ($type == 'folder')
- {
- $newentry['path'] = $newentry['path'] .'/';
-
- if (glob(quotemeta($newentry['path']) .'*'))
- $folderlisting[] = $newentry;
- }
- else
- $filelisting[] = $newentry;
+ $date = preg_replace('/-/', '/', substr($value, 0, 10));
+ $time = preg_replace('/\./', 'h', substr($value, 11, 5));
+ $recnice = $date .' at ' .$time;
+ //$newentry['name'] = $recnice;
+ $folderlisting[] = $newentry;
break;
default:
}