From 2801dae0767b84d0e6b842e55dbef5b656eb65f7 Mon Sep 17 00:00:00 2001 From: Karl 'vollmerk' Vollmer Date: Sun, 20 Apr 2008 22:35:21 +0000 Subject: fixed show album art, added input for source charset on fix_filenames, added "add" to shoutbox display, updated links --- bin/fix_filenames.inc | 16 ++++++++++++++-- docs/CHANGELOG | 3 +++ docs/README | 12 ++++++------ lib/class/xmlrpcclient.class.php | 2 +- server/browse.ajax.php | 2 +- templates/show_live_streams.inc.php | 7 ++++++- templates/show_shout_row.inc.php | 2 +- templates/show_shoutbox.inc.php | 5 +++-- 8 files changed, 35 insertions(+), 14 deletions(-) diff --git a/bin/fix_filenames.inc b/bin/fix_filenames.inc index 32ceedf2..cff22589 100644 --- a/bin/fix_filenames.inc +++ b/bin/fix_filenames.inc @@ -42,12 +42,20 @@ if (!function_exists('iconv')) { exit; } +// Attempt to figure out what the System Charset is +$source_encoding = iconv_get_encoding('output_encoding'); + // Attempt a simple translation $string = iconv(Config::get('site_charset'),Config::get('site_charset'),'For the Love of Music'); echo "Testing Basic Translation, the two strings below should look the same\n"; echo "Original: For the Love of Music\n"; echo "Translated: $string\n"; echo "---------------------------------------------------------------------\n"; +echo "Input Charset ($source_encoding):"; +$input = trim(fgets(STDIN)); + +if (strlen($input) > 0) { $source_encoding = trim($input); } +echo "Using $source_encoding as source character set\n"; $sql = "SELECT * FROM `catalog` WHERE `catalog_type`='local'"; @@ -55,10 +63,13 @@ $db_results = Dba::query($sql); while ($row = Dba::fetch_assoc($db_results)) { + echo "Checking " . $row['name'] . " (" . $row['path'] . ")\n"; charset_directory_correct($row['path']); } // end of the catalogs +echo "Finished checking filenames for valid chacters\n"; + /************************************************** ****************** FUNCTIONS ********************* @@ -103,9 +114,10 @@ function charset_directory_correct($path) { continue; } - $translated_filename = iconv(Config::get('site_charset'),Config::get('site_charset') . '//IGNORE',$full_file); + $verify_filename = iconv(Config::get('site_charset'),Config::get('site_charset') . '//IGNORE',$full_file); - if (strcmp($full_file,$translated_filename) != '0') { + if (strcmp($full_file,$verify_filename) != '0') { + $translated_filename = iconv($source_encoding,Config::get('site_charset') . '//IGNORE',$full_file); echo "Attempting to Transcode to " . Config::get('site_charset') . "\n"; echo "--------------------------------------------------------------------------------------------\n"; echo "OLD:$full_file has invalid chars\nNEW:$translated_filename\n"; diff --git a/docs/CHANGELOG b/docs/CHANGELOG index ae4e480a..394846bb 100755 --- a/docs/CHANGELOG +++ b/docs/CHANGELOG @@ -4,6 +4,9 @@ -------------------------------------------------------------------------- v.3.4-Beta3 + - Added prompt for input charset to fix_filenames.inc + - Updated Links in Readme + - Fixed Show Art filter on browse by albums - Added Ratings links to Browse Albums and Browse Artist - Fixed seeking on random track, giving you a new track every seek diff --git a/docs/README b/docs/README index d9847ad8..36f18652 100755 --- a/docs/README +++ b/docs/README @@ -61,16 +61,16 @@ Contents: - ASX - RAM - XSPF - - Realtime Downsampled - - XSPF Based Flash Player + - Realtime Downsampling + - Integrated Flash Player - Automatic Downsampling based on load - Local/Remote network definition based downsampling - On the Fly Transcoding - Localplay - Music Player Daemon (MPD) - Winamp using (HTTPQ) - - Democratic Vote based play - - 3rd Party clients using API (Amarok) + - Democratic Vote based playback + - 3rd Party clients using API (Amarok,Coherence) C) Current Translations @@ -150,8 +150,8 @@ Contents: Public SVN: https://svn.ampache.org/ IRC: irc.ampache.org #ampache (Freenode) Forums: http://ampache.org/forums - Bugs: http://trac.ampache.org/ - Wiki: http://trac.ampache.org/wiki + Bugs: http://ampache.org/bugs + Wiki: http://ampache.org/bugs/wiki Demo: http://ampache.org/demo Ampache Development Team diff --git a/lib/class/xmlrpcclient.class.php b/lib/class/xmlrpcclient.class.php index 88174880..361d7e94 100644 --- a/lib/class/xmlrpcclient.class.php +++ b/lib/class/xmlrpcclient.class.php @@ -126,5 +126,5 @@ class xmlRpcClient { } // create_client -} // xmlRpcServer +} // xmlRpcClient ?> diff --git a/server/browse.ajax.php b/server/browse.ajax.php index 35a90d81..a3673173 100644 --- a/server/browse.ajax.php +++ b/server/browse.ajax.php @@ -31,7 +31,7 @@ switch ($_REQUEST['action']) { // Check 'value' with isset because it can null //(user type a "start with" word and deletes it) - if ($_REQUEST['key'] && isset($_REQUEST['multi_alpha_filter'])) { + if ($_REQUEST['key'] && (isset($_REQUEST['multi_alpha_filter']) OR isset($_REQUEST['value']))) { // Set any new filters we've just added Browse::set_filter($_REQUEST['key'],$_REQUEST['multi_alpha_filter']); } diff --git a/templates/show_live_streams.inc.php b/templates/show_live_streams.inc.php index 631ee177..897c34dd 100644 --- a/templates/show_live_streams.inc.php +++ b/templates/show_live_streams.inc.php @@ -1,7 +1,7 @@ + + + + + diff --git a/templates/show_shout_row.inc.php b/templates/show_shout_row.inc.php index a57b8594..fbc88c95 100644 --- a/templates/show_shout_row.inc.php +++ b/templates/show_shout_row.inc.php @@ -1,7 +1,7 @@
get_image(); ?> - object_type); ?>: f_link; ?> + object_type .' &id=' . $shout->object_id,'add',_('Add'),'add_' . $shout->object_type . '_' . $shout->object_id); ?> + f_link; ?> f_link; ?> date); ?> text); ?>
-- cgit