summaryrefslogtreecommitdiffstats
path: root/lib/class/song.class.php
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-01-22 08:39:24 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-01-22 08:39:24 +0000
commit56ce11f771d173f559f2608c83422a94fcc37165 (patch)
treed537804a9c707cf7fb1743fb8d112bb87040f718 /lib/class/song.class.php
parent595b211d5e59e320586d09e16878b24bdb8b3375 (diff)
downloadampache-56ce11f771d173f559f2608c83422a94fcc37165.tar.gz
ampache-56ce11f771d173f559f2608c83422a94fcc37165.tar.bz2
ampache-56ce11f771d173f559f2608c83422a94fcc37165.zip
added config version check, fixed play selected bug reported by chenb and fixed wmp11 now playing issue
Diffstat (limited to 'lib/class/song.class.php')
-rw-r--r--lib/class/song.class.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/lib/class/song.class.php b/lib/class/song.class.php
index 26c218a7..c7fcd658 100644
--- a/lib/class/song.class.php
+++ b/lib/class/song.class.php
@@ -162,8 +162,7 @@ class Song {
preg_match('/\.([A-Za-z0-9]+)$/', $this->file,$results);
$this->type = strtolower($results['1']);
}
-
-
+
switch ($this->type) {
case 'spx':
case 'ogg':
@@ -201,7 +200,9 @@ class Song {
break;
}
- } // get_type
+ return true;
+
+ } // format_type
/*!
@function get_album_songs
@@ -817,10 +818,10 @@ class Song {
}
/* Account for retarded players */
- if ($song->type == 'flac') { $type = 'ogg'; }
+ if ($this->type == 'flac') { $type = 'ogg'; }
$this->format();
- $song_name = rawurlencode($this->f_artist_full . " - " . $this->title . "." . $this->type);
+ $song_name = rawurlencode($this->f_artist_full . " - " . $this->title . "." . $type);
$web_path = conf('web_path');
@@ -856,7 +857,7 @@ class Song {
if (conf($conf_var)) {
$this->_transcode = true;
$this->format_type(conf($conf_type));
- debug_event('auto_transcode','Transcoding to ' . conf($conf_type),'5');
+ debug_event('auto_transcode','Transcoding to ' . $this->type,'5');
return false;
}