diff options
-rw-r--r-- | bin/dump_album_art.inc | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/bin/dump_album_art.inc b/bin/dump_album_art.inc index d9d4e44b..2a22bffa 100644 --- a/bin/dump_album_art.inc +++ b/bin/dump_album_art.inc @@ -1,7 +1,7 @@ <?php /* - Copyright 2001 - 2007 Ampache.org + Copyright Ampache.org All Rights Reserved This program is free software; you can redistribute it and/or @@ -24,11 +24,16 @@ $path = dirname(__FILE__); $prefix = realpath($path . '/../'); require_once $prefix . '/lib/init.php'; -// If we specify extra meta data -// Possible values are windows and linux -// If Null then no meta data is dumped +// Turn off output buffering we don't need it for a command line script +ob_end_clean(); + $meta = 'linux'; +// Take input from the command line, two options linux or windows +if (count($_SERVER['argv']) > 1) { + $meta = ($_SERVER['argv']['1'] == 'windows') ? 'windows' : 'linux'; +} + $catalogs = Catalog::get_catalogs(); foreach ($catalogs as $catalog_id) { |