summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-04-22 19:05:59 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-04-22 19:05:59 +0000
commit9c65bbb26cf5ee302ce8bfa4a196c3f8255ac359 (patch)
tree255f0627f4feea73aea22446f2725dfa9634c6b8
parente3a736e7efd4b8f9a36e0c246adf9605e47e7eb0 (diff)
downloadampache-9c65bbb26cf5ee302ce8bfa4a196c3f8255ac359.tar.gz
ampache-9c65bbb26cf5ee302ce8bfa4a196c3f8255ac359.tar.bz2
ampache-9c65bbb26cf5ee302ce8bfa4a196c3f8255ac359.zip
reverted change, the &amp does work because this isnt displayed by a browser
-rw-r--r--lib/class/catalog.class.php18
-rw-r--r--lib/class/song.class.php6
2 files changed, 6 insertions, 18 deletions
diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php
index 43becdac..57186865 100644
--- a/lib/class/catalog.class.php
+++ b/lib/class/catalog.class.php
@@ -1212,24 +1212,12 @@ class Catalog {
flush();
}
- /* Add this file to the list for removal from the db */
- $dead_files[] = $results;
- } //if error
-
- } //while gettings songs
-
- /* Incase there's been a snafo with a mount point on something
- * don't actually delete from DB here, simply disable and list
- */
- if (count($dead_files)) {
- foreach ($dead_files as $data) {
-
- $sql = "DELETE FROM song WHERE id='$data->id'";
+ $sql = "DELETE FROM song WHERE id='" . $results->id . "'";
$db_results = mysql_query($sql, dbh());
- } //end foreach
+ } //if error
- } // end if dead files
+ } //while gettings songs
/* Step two find orphaned Arists/Albums
* This finds artists and albums that no
diff --git a/lib/class/song.class.php b/lib/class/song.class.php
index c6fdcff9..d1a985b4 100644
--- a/lib/class/song.class.php
+++ b/lib/class/song.class.php
@@ -711,12 +711,12 @@ class Song {
$username = $GLOBALS['user']->username;
$song_id = $this->id;
if (conf('require_session')) {
- $session_string = "&amp;sid=" . session_id();
+ $session_string = "&sid=" . session_id();
} // if they are requiring a session
$type = $this->type;
if ($GLOBALS['user']->prefs['play_type'] == 'downsample') {
- $ds_string = "&amp;ds=" . $GLOBALS['user']->prefs['sample_rate'];
+ $ds_string = "&ds=" . $GLOBALS['user']->prefs['sample_rate'];
}
/* Account for retarded players */
@@ -724,7 +724,7 @@ class Song {
$this->format_song();
$song_name = rawurlencode($this->f_artist_full . " - " . $this->title . "." . $this->type);
- $url = conf('web_path') . "/play/index.php?song=$song_id&amp;uid=$username$session_string$ds_string&amp;name=$song_name";
+ $url = conf('web_path') . "/play/index.php?song=$song_id&uid=$username$session_string$ds_string&name=$song_name";
return $url;