Image 01
profile-image

crosscut

Rob Rob Turner
ObsidianMusic

Audio Apps by ObsidianX 47 comments

Thanks for the fast update. This works great!

stream.php:

$devid = $res['deviceid'];
$qd = query(getquery("getdevice", "", $devid));
$resd = fetch_assoc($qd);

$url = $resd['lastmountpoint'].ltrim($url, '.');

Note that pages/play.php also contains multiple references to $url. I presume similar code need to be added here to tar files correctly? - Sep 16 2006
ObsidianMusic

Audio Apps by ObsidianX 47 comments

It appears the database structure has changed slightly with the latest version of amarok.

The true path to my media is:
/home/warehouse/multimedia/Music/artist/song.mp3

MySQL shows the url as being:
./warehouse/multimedia/Music/artist/song.mp3

I've noticed that the following query reveals the top level that is missing from the url:

mysql> select lastmountpoint from devices;
+----------------+
| lastmountpoint |
+----------------+
| /boot |
| /home |
+----------------+

Until this lastmountpoint can be applied in the code. This is how I fixed my streaming of individual files:

pages/stream.php

$url = '/home'.ltrim($url,"."); // Add this line with lastmountpoint location
echo file_get_contents($url); - Sep 16 2006