Printable Version of Topic

Click here to view this topic in its original format

AMIP Community _ Support _ How to Write Song info to a file as an array?

Posted by: Mohit Jun 5 2014, 09:40 AM


I found about AMIP via Google, and then have been using it to display my current track info on my website.

Here's a link to how I've used (AMIP + Dropbox + Scripts) to update song info on my website. : [ ]

I'm not trying to post info of latest 5 tracks I've played via winamp, on my website.. For that I need an array or text based output being written to the out.html file from AMIP...

For example, array being written could be as follows:

var song_array = {
i:1, song:"Levels", artist:"Avicii",
i:2, song:"All Night", artist:"Icona Pop",
i:3, song:"Million Voices", artist:"Otto Knows"
i:4, song:"Chill House", artist: "True",
i:5, song:"Harlem", artist:"New Politics"

Now whenever a new songs is played, it should be added as the 1st track, pushing i:1 downwards, so that the 5th track is removed from the out.html, and 4th becomes 5th track, and so on...

I know this can be done via PHP + SQL, but I don't own a host that could allow fetching and changing of data every 5 minutes of track change... Currently I'm using dropbox to keep the out.html online, but dropbox doesn't support PHP.

Could someone provide help regarding this?


Powered by Invision Power Board
© Invision Power Services