0
Hi Germi,
Just a small question for once...
In which file are the songs_position_id & songs_position_url scripts added to MC pages?
Many thanks,
Gez
Just a small question for once...
In which file are the songs_position_id & songs_position_url scripts added to MC pages?
Many thanks,
Gez
Responses (11)
-
Accepted Answer
-
Accepted Answer
0@germi
Hi Germi,
I have a small issue in that the songs_position_url seems to prepend '/songs/' to the path so that a song 'songs/ev-rct11/s/1-03 Love the Food, Hate the Waste.m4a' in the JS of a given page ends up as '/songs//songs/ev-rct11/s/1-03 Love the Food, Hate the Waste.m4a'.
Songs are playing fine however, I'm not using HTML5 player yet and I'm mindful that when I do, I'm going to run into an issue with this.
Where can I change this?
Usure if this is in anyway related but, in my XSPF helper, I had to change the item->location using a string replace in order to get the streaming working for flash player like;
$data->items[$i]->location = str_replace("/songs",$songs_lts,$data->items[$i]->location);
Many thanks,
Gez -
Accepted Answer
-
Accepted Answer
-
Accepted Answer
0Hi Germi,
Thanks!
For some reason, I can't get this to work properly - I must be missing something.
There are 2 helper functions that I'm editing at the moment... The 'getSongFileURL' & 'getSongFileURLslashes'...
For the moment, as I sort of know what I'm doing and for debugging, I've commented out everything inside of both functions and am just returning $song_path_complet as follows;
function getSongFileURL($song){
$song_path_complet = "songs/" . $song->filename ;
return $song_path_complet ;
}
this means of course, that I'm hardcoding the songs folder which isn't a problem just for testing. However, somehow, 'songs/' is getting prepended to it still so that files in'songs/1/' become 'songs/songs/1'.
Even stranger is the fact that the XSPF feed for the album that I'm looking at displays it correctly and it plays fine however, in the JS array of songs (songs_position_url) it has the extra 'songs/' prepended to the path????
Very strange!
I can't work out what's going on here...
Many thanks,
Gez
P.S. If you need to see my site to debug, please could you email me your IP address so I can add it to HTACCESS? I'll send you an email so you got my address to hand. Thanks, Gez -
Accepted Answer
0Hi Germi,
Just to clarify a bit further, all of my media is initially uploaded to [root]/songs/ on my server. Then, the songs directory and all of it's contents gets sync'd to cloudfront with the same relative folder structure as on my site.. Since I'm streaming at the moment, I don't need to add my base URL to the filename as the streamer variable serves the same purpose.
When I come to setup HTML5, I'm going to prepend my amazon S3 server URL to the filenames so that rather than Flash streaming, it will use progressive download to play the media from my bucket instead. Since this S3 bucket is the source of my Cloudfront distribution, the files and dirs are also all relative to my web servers directories.
Thanks, Gez -
Accepted Answer
-
Accepted Answer
0Hi Germi,
No, I haven't printed the song array to check as such but, as I said, the strange thing is that the filename/path in the XSPF view of the album is correct... It's just the link in the JS stuff where I get 'songs/songs/...'
Any ideas?
Thanks Gez!
BTW I almost have my MC JW player module docked in fixed location. Now I'm working on a bit of JS to resize the player so I can toggle the screen, control bar and playlist elements separately.
I will post this once I'm done - prob next week some time
Your Reply
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »