Copy link to clipboard
Copied
So I've been working on a little flash media player (only plays music) and I want to add an option where you can click the name of a song and it'd play it.
Doesn't seem too complex, corrent? Well I'm stuck.
What I have added:
Play, Pause, Reverse (goes back 1 song), and fast forward (goes forward 1 song)
Song data display (shows title and artist of each song)
Scrollbar (To scroll through the songs (Broken temporarly, idk why))
Array to place all the Movie clips (1 per song) in a box so you can click them.
and some other stuff.
The issue:
I can't pinpoint a good way to figure out what song is clicked for the player to know which song to switch to.
It loads via xml and plays using an int. The current_song int can only go as high as there are songs within the xml. If it goes further it resets to 0 and starts the list over.
So what I need it to do is set each song item within the array of movie clips to a number. When clicked the current_song int would change to that number, and then play the selected song.
I'm sorry if I'm confusing you. I'll try and explain better if you can't understand.
Copy link to clipboard
Copied
Whatever list/combobox you are presenting for making the choices should carry the number as a piece of data... show the song title as the label but assign the number as the data for that entry.
Copy link to clipboard
Copied
I got everything working correctly.
But as soon as I upload it to my web host, it doesn't work.
It works locally if I run the .swf natively, and if I run the html locally.
But online it won't work.
What could be causing this?
Copy link to clipboard
Copied
It could be missing a file or more. Make sure your xml and sound files are all where they need to be relative to the html/swf.
Copy link to clipboard
Copied
It's not missing anything from what I see. I re-uploaded everything that I was using locally. Still got the same bug.
I think it's something to do with my webhost.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now