View Full Version : Loading WMA's in a seperate player

11-01-2005, 05:25 PM
Hi everyone,
I am currently constructing a page for a DJ and his friend. They intend to host their music on their FTP server. They have requested though that the WMA's load up in Windows Media Player, seperate to the site, e.g. When you click on the link, it opens WMP. I was wondering if anyone had any ideas on how to do this. I am stuck and dnt have a clue.

This obviously means that they will want to be able to update the name of the link themselves also, therefore i have made the links movie symbols with text boxs linked to external text files (if that makes sence) e.g. when they update the text file, the link name will change.

Any help would be great and its due for completion soon.
Its only my second site iv ever built.

Check out my first here; www.burnonfire.com


P.S. I keep getting a problem with this code --

this.onRelease = function() {
import mx.managers.PopUpManager;
import mx.containers.Window;
win = PopUpManager.createPopUp(_root, mx.containers.Window, true, {title:"Ryan Skelley Designs", contentPath:"Website.jpg", closeButton:true});
win.setSize(619.6, 464.7);
win.move(win.x + 71.7, win.y + 42.5);
lo = new Object();
lo.click = function() {
win.addEventListener("click", lo);

I know that it is because the code is a MX04 code but i dnt know how to update it. It should produce a nice pop-up flash window.



Flash Gordon
11-01-2005, 06:13 PM
They have requested though that the WMA's load up in Windows Media Player
getURL("media1.wma", "_blank");

Next, to let them update the link. I would keep most (or all) of my actionscript in a external .as file. Let them update that with notepad.

11-01-2005, 06:50 PM
Gordon's example should work fine, but you do run the risk of the WMA opening in a player besides Windows Media Player if the end user has a different app set to play WMAs (if that matters to you at all). If you want to force users to use Windows Media Player, you need to embed the files into an HTML document of some sort. To do that you can use code like :

<object id="MediaPlayer" classid="CLSID:22D6f312-B0F6-11D0-94AB-0080C74C7E95" standby="Loading Windows Media Player components..." type="application/x-oleobject" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,7,1112">

<param name="YOUR SONG TITLE" value="YOUR FILENAME">
<param name="Showcontrols" value="True">
<param name="autoStart" value="True">

<embed type="application/x-mplayer2" src="YOUR FILENAME" name="MediaPlayer"></embed>


You can run a google search on embeding wmas as well, there's a wealth of info out there!

Is the Burn site you posted a beta version? Only reason I ask is that the initial download is HUGE. 3.5 megs! Even broadband users might cringe at a website that huge. You might want to look into splitting your Flash into sections and not requiring your users to download the entire thing at once.

11-01-2005, 07:03 PM
Nah that was the final page. Im new to this so you would have to explain what to do regarding the Burn website.

If you can that would be great!

No thoughts on the opening window then??

I dnt think they are too bothered about using a different player, i just wasnt too sure if that code would work.

Fanx Guys


11-03-2005, 12:19 PM
I could really do with some help concerning the window pop-up if anyone can help


11-06-2005, 12:40 AM
So im using the idea suggested above by Flash Gordon, and im getting a problem. If i use mp3's the idea works great. With WMA's Windows Media gives me an error saying it cant find the file.

Also i would just like to say, for the amount of people on this forum, we never seem to have many replies. Maybe i will change to another forum...

Please give me some help.