;

PDA

Click to See Complete Forum and Search --> : HTML/Flash mp3 Player


bobgodwin
08-11-2006, 07:04 PM
I Wanted a really simple mp3 player to ues as a link from other sites (MySpace, blogs, groups, etc.) I made a small .swf with action script on each frame to call up the .mp3. I use this code in an .html doc to run the .swf:

<a href="javascript:;" onclick="window.document.snd_hifi.GotoFrame(2);">Song 1</a>

Works great as a popup player, but looks O.K. in a open window too.

The .html navigation moves everything up a frame. GotoFrame(1) in the .html goes to Frame 2 in the .swf and so on. When I change the Key Frame names, it doesn't work. The .html won't call up the new names for some reason.

Only Song 9 works in this example (They all work in the online example). Change the .fun file to make the rest work.

Popup Players (http://bigearthweb.com/bobgodwin/popup player link.html)

KoolMoves Player (http://bigearthweb.com/bobgodwin/koolmoves_player.html)

ant_Z
08-12-2006, 11:36 AM
<a href="javascript:;" onclick="window.document.snd_hifi.GotoFrame(2);">Song 1</a>

try href="javascript:void();" - some older browsers may have problems with your link.

maybe try GotoFrame('framename'); ?

a long time ago ive tried to make a html link to key frame in flash, using PHP $_GET array, but it seemed to dont work. You can try that way; when ill find the code ill post it.

bobgodwin
08-12-2006, 04:20 PM
The "void()" works, but causes a script error to popup. "GotoFrame" goes to a frame number, no matter what it is named. I tried ("framename") and all the variations, with more errors. But you can make a 100 frame .swf with code for a different song on each and change the code in the .html to call up the right frame. Makes for simple editing of song links.