ActionScript 2.0 :: LoadSound From Php Url?

Jan 28, 2010

actionscript and i have a mp3 player that loads an mp3 file from a certain url. my code is this:ow can i change this to load an mp3 file from a php code exactly like this:

<?php echo base_url(); ?>uploads/<?php echo $artist_id; ?>/music/<?php echo $filename; ?>

View 1 Replies


Similar Posts:


ActionScript 2.0 :: LoadSound Won't Play In IE

Nov 3, 2004

i have a script on a frame at the root of the movie.

[Code].....

the problem is, that the sound isnt loading in Internet Explorer. I thought it may have been SP2 causing problems but i went and tested it on school's computer SP1 and it still didnt work. In firefox it works fine, so the AS must be correct (which im positive it is) i just cant work out for the life of me why it isnt loading. I have also tried loading the sound onto a movieclip and not from the frame
i.e.

[Code]....

and this didnt work in IE either. Works again in firefox though.

View 1 Replies

ActionScript 2.0 :: LoadSound Prob

Jan 7, 2006

I applied folowing script to load my mp3 file. Problem is my mp3 won't loop:s. Anyone see the prob in my script? i'd also like the mp3 to fade in and when I push the stop button it fades out.

loopSound = function () {
myMp3.loadSound("streamsound.mp3", true);
myMp3.setVolume(50);[code]...

View 1 Replies

ActionScript 2.0 :: LoadSound Won't Play In IE?

Nov 3, 2004

i have a script on a frame at the root of the movie.

// background sound (war environment)
_global.bgsound = new Sound();
bgsound.loadSound("sounds/mp40.mp3")

[Code].....

the problem is, that the sound isnt loading in Internet Explorer. I thought it may have been SP2 causing problems but i went and tested it on school's computer SP1 and it still didnt work. In firefox it works fine, so the AS must be correct (which im positive it is) i just cant work out for the life of me why it isnt loading. I have also tried loading the sound onto a movieclip and not from the frame i.e.

// background sound (war environment)
_root.createEmptyMovieClip("myEmptyMC","2");

[Code].....

and this didnt work in IE either. Works again in firefox though.

View 1 Replies

ActionScript 2.0 :: CS3 Mp3 Using LoadSound Restarting After 2 Seconds

Mar 8, 2009

I'm having some trouble with loadSound. I've created a portfolio section for a company that has short (1:30) mp3 clips. The clips are being loaded in dynamically through an XML doc. For whatever reason, when the sound loads, it plays for almost exactly 2 seconds, then restarts and plays all the way through. My flash is set up in three frames, the first two are the main gallery, then frame three is where the sound is loaded and played. "p" is defined by which icon in the gallery is clicked.

[Code]...

View 2 Replies

ActionScript 3.0 :: LoadSound With Large Mp3 Files?

Jan 21, 2009

I'm writing a small mp3 player. It reads the playlist from an xml file, then at the end of a song (or when the "Next" button is pressed) automatically plays the next song in the list.My problem is that if the song is a large file (around 16MB), the player doesn't play the song -- I have to click pause then play a couple of times to play it.

The code is roughly:

Code:
function playSong():Void
{
tune = new Sound();

[code]....

where 'tunes' is an array of paths to the file. I've missed out a couple of things, but that's basically it. Is there an issue with loadSound needing to load some of the song first?

View 0 Replies

ActionScript 2.0 :: LoadSound With Large Mp3s?

Jan 22, 2009

I originally posted this wrongly in AS3, I'm writing a small mp3 player. It reads the playlist from an xml file, then at the end of a song (or when the "Next" button is pressed) automatically plays the next song in the list.

My problem is that if the song is a large file (around 16MB), the player doesn't play the song -- I have to click pause then play a couple of times to play it.

[Code]...

View 0 Replies

ActionScript 2.0 :: Loadsound Compression Details?

Apr 28, 2006

was wondering how sound files are compressed when they are retreived using the loadsound command? do they use the original file compression or does flash muck about with it? The reason i ask is that an audio file is coming out sounding very different to the original

View 1 Replies

ActionScript 2.0 :: LoadSound Selective Lockup?

Sep 26, 2008

I've got a quirk here I'm having a difficult time hammering out.I've got a control object with a sound object as a child. This global sound object has another sound object as a child:

Code:
Master = {};
Master.soundManager = new Sound();
Master.soundManager.BGM = new Sound();
\
In the main loop of my program, I have a function (VNELineReader()) with a switch looking for particular cues, one of which is loading a sound into BGM:

Code:
case "bgm_load" :
Debug.trace('Loading music: Sound/'+args+'...');
Master.soundManager.BGM.onLoad = function() {[code].....

Now, when I run this in the Flash 8 IDE, no problems. The script waits for the sound to load, resumes, and later on plays BGM with a case "bgm_play". However, if I compile the program and play it with the external flash player, the loadSound call causes the player to freeze, eat up about 600MB of memory in task manager, and then crash. It also does this if I open the .swf in Internet Explorer. However, it works fine in Firefox.

View 1 Replies

ActionScript 3.0 :: LoadSound With Large MP3 Files

Jan 22, 2009

I'm writing a small mp3 player. It reads the playlist from an xml file, then at the end of a song (or when the "Next" button is pressed) automatically plays the next song in the list. My problem is that if the song is a large file (around 16MB), the player doesn't play the song -- I have to click pause then play a couple of times to play it.

The code is roughly:
function playSong():Void {
tune = new Sound();
tune.onSoundComplete = playSong;
tune.loadSound(tunes[++current],true);
}

Where 'tunes' is an array of paths to the file. I've missed out a couple of things, but that's basically it. Is there an issue with loadSound needing to load some of the song first?

View 2 Replies

ActionScript 2.0 :: Mp3 Using LoadSound Restarting After 2 Seconds?

Mar 8, 2009

I'm having some trouble with loadSound. I've created a portfolio section for a company that has short (1:30) mp3 clips. The clips are being loaded in dynamically through an XML doc.

For whatever reason, when the sound loads, it plays for almost exactly 2 seconds, then restarts and plays all the way through.

My flash is set up in three frames, the first two are the main gallery, then frame three is where the sound is loaded and played. "p" is defined by which icon in the gallery is clicked.

Here is my code for reference:

Code:
import mx.transitions.Tween;
import mx.transitions.easing.*;
if (p == 0) {

[Code]....

View 1 Replies

ActionScript 2.0 :: LoadSound Doesn't Loop?

Jan 1, 2004

why this doesn't work? I'm about to go crazy! It's just supposed to be background music and it plays once then stops. WHY?

[AS]
backsound = new Sound();
backsound.loadSound("sounds/loopy.mp3", true);

[code]....

View 1 Replies

ActionScript 2.0 :: Cross Domain LoadSound Woes?

Jul 24, 2009

I'm trying to load an MP3 file from a different domain using loadSound while publishing from flash?

View 1 Replies

ActionScript 2.0 :: LoadSound Doesn't Make The Loop

Jan 1, 2004

It's just supposed to be background music and it plays once then stops. WHY?

[AS]
backsound = new Sound();
backsound.loadSound("sounds/loopy.mp3", true);
backsound.onSoundComplete = backsound.start;
[/AS]

I have also tried backsound.start(0,999); but it doesn't work either.

View 1 Replies

ActionScript 2.0 :: LoadSound False - When Set It To True It Does Play?

May 3, 2004

I have a button that imports an mp3 and is supposed to load completely before playing. Problem is, when I set the loadSound to false it doesn�t play at all, but when I set it to true it does play. Here is the code:

Code:
carregarSons = function (som, numeroVolume) {
_root.som1.stop();
_root.som1 = new Sound()[code]....

View 8 Replies

ActionScript 2.0 :: LoadSound Randomly On Initial Start?

Oct 15, 2007

I have an MP3 player that i want to put on my site, I would like to have the first song be played randomly so it dosent grow stale.

Here is the A.S. i'm using.

Code:
var musicFolderName:String = "music/";
var curTrackNum:Number = 0;
var curPlaybackPos:Number;

[Code]......

View 4 Replies

ActionScript 2.0 :: How To Get LoadSound To Read Correct Path

Dec 4, 2007

What I'm trying to do is for a play button to just play the first thing that is on my XML file. I have the XML file played out like this and it is being loaded earlier in the actionscript file.

<song>
<loc>testaudio/fire.mp3</loc>
<songtitle>Fire</songtitle>
<artist>Jim</artist>
<album>Album #1</album>
[Code] .....

The mySound.loadSound(loc[0]); is coming up with an unknown, and this is because the file path is not in quotes because it wants a URL, not a variable (loc[0] should be passing on the file path for the first song in the XML file). Is there some way to change the variable so that the loudSound() function reads the path correctly? It works fine when I just pop the file path in there instead of loc[0].

View 3 Replies

ActionScript 2.0 :: Loadsound External Mp3 And Play From Middle

Apr 27, 2009

I am unable to play the mp3 from the middle

[Code]...

View 1 Replies

ActionScript 2.0 :: LoadSound/attachSound Lowers The Original Pitch?

Feb 3, 2010

i am having this very big problem(for my particular application). i am writing this music application in flash and i use as2 to load randomly specific sounds which are in the same folder as the movie. the problem is that i need the sound to be replayed with fidelity and it seems flash is lowering the pitch of the "music" by a halfstep(it does the same when "previewing" it from the library). musically speaking, if i have an mp3 containing A at 440 hz played with piano timbre, Flash will lower it and when it is played through the flash player is its played as a G sharp(35 hz lower). I thought that if i will replace the attachSound with loadSound and the sound will be loaded externally and not from the library the problem will be solved. it seems that this won't solve the probem. the sound just doesn't want to be played at the frequency it has in the file from which is loaded. i had read somewhere that this is a flash player's bug.

View 8 Replies

ActionScript 2.0 :: Stop Streaming LoadSound From Starting Immediately?

Nov 9, 2010

I have an AS2 file where I want to load an external sound, but not have it start until the play button is pushed. It is a large file so I want it to load streaming, but can't figure out how to keep the streaming true without having it start immediately. Here is the code:

this.createEmptyMovieClip("craigTalks_mc", 10);
craigTalks = new Sound(craigTalks_mc);
craigTalks.loadSound("mp3/Craig_BP.mp3", true);[code]....

I have three audio files using the same code that I want the user to be able ot toggle on and off. When I set the loadSound isStreaming variable to false, it works perfectly, but at true, all three files start at once, and the pause doesn't work! However if I keep it at false, once I load it to the website it doesn't work, I believe because it is taking too long for the audio files to load.

View 4 Replies

ActionScript 2.0 :: Stop MP3 From Cache'ing Streaming Sound Using Loadsound?

Jul 19, 2004

I have used the loadsound command with the streaming option set to true, so it streams sound etc. But the problem is that it cache's the mp3 file it is streaming onto the user's internet cache folder Is there a way to prevent mp3 files from being cached (have I murdered the English language today using the word cache? ) Something like what the Real Player does, it streams the files but never cache's them. <gasp>

View 7 Replies

ActionScript 2.0 :: Check For Missing File If Loaded Into LoadSound()?

Apr 19, 2009

I have built an Mp3 player for my site and users are allowed to put their own music into the playlist. The only problem I have run into now is that if the URL becomes invalid later, the player will stop at that song and the user would have to press next to skip to the next song. Is there any way to get the player to do this on it's own?

Code:
AudioPath = aPath[current_song-1];
song_text.text = songTitle[current_song-1]+" / "+bandTitle[current_song-1];
MySound = new Sound();

[code]....

View 2 Replies

ActionScript 2.0 :: Stop MP3 From Cache'ing Streaming Sound Using Loadsound

Jul 19, 2004

I created a streaming mp3 player, the Click here for player

I have used the loadsound command with the streaming option set to true, so it streams sound etc. But the problem is that it cache's the mp3 file it is streaming onto the user's internet cache folder.

Is there a way to prevent mp3 files from being cached (have I murdered the English language today using the word cache? ) Something like what the Real Player does, it streams the files but never cache's them. <gasp>

View 12 Replies

Actionscript :: LoadSound: Don't Wait For The Entire Download Before Play But Not Have It Start Automatically

Jul 2, 2009

I am trying to play an MP3 using Actionscript 2. I have the following requirements: I don't want to wait for the MP3 to load before playing it. I want to know when enough of the MP3 has downloaded that I can start playing it. I don't want the MP3 to start playing immediately: I need to control when the play starts. An example scenario is that I need to start playing a 30-second MP3 exactly 8 seconds from now (at the top of the minute, let's say). Depending on the connection, I may or may not be able to download the entire MP3 by then, but I can almost certainly download enough to start playing without interruption.

[Code]....

View 2 Replies

ActionScript 3.0 :: Script Error - Frame 1, Line 1061 : Call To A Possibly Undefined Method LoadSound...?

Dec 11, 2010

import flash.media.Sound;
//Setup sound object
var s:Sound = new Sound();[code]....

I cant run this code, it throws an error:[code].....

View 1 Replies

ActionScript 1/2 :: Rollover Buttons To Play Sound Using "loadSound"?

Apr 20, 2011

The target effect: Rolling over each of the two buttons on the main stage plays different sound. The code below works. However, I need to embed it in another application (Articulate) which doesnot allow the use of "_root" and "attachSound". I was recommended to use "loadSound" instead. However, not a coding person, I am at a loss.to change the script below to remove "_root" and "attachSound" and use "loadSound" instead

var mySound:Sound = new Sound();mcButton5.onRollOver = function() { _root.mySound.attachSound("sound1"); _root.mySound.start();
var mySound:Sound = new Sound();mcButton6.onRollOver = function() {

[code].....

View 15 Replies

ActionScript 2.0 :: Sound.loadSound("1.mp3",false) Not Working?

Mar 3, 2006

sound.loadSound("1.mp3",false)where 1.mp3 is residing in my current folder (as the swf).However, the sound does not get played. It is only played when I say:sound.loadSound("1.mp3",true) //(hence a streaming sound)I want the first one to work, in order to be able to use the onSoundComplete event

View 11 Replies

ActionScript 2.0 :: [FMX] LoadSound - Sound To Keep Playing While The Rollovers Load Sound

Jun 22, 2003

I am loading small sounds dynamically with the loadSound command. These small sounds are activated with a rollover. see script below. This works ok. however. i want the first sound to keep playing while the rollovers load sound. a bit like playing the piano. This works ok when i import all the sounds into the library and place them on their very own button. however the size of the flash movie increases to 140k. whereas when i load them dynamically the size of the movie is 20k. obviously i want to load dynamically.

But with dynamic loading each sound stops when another sound is rolled over, so that there is only ever one sound playing at once. I need to load the sound into a different level or something, so that the first sound can keep going while the smaller, shorter sounds play over the top. this is my script below. The first sound loads when the movie starts. This is the one i want to keep playing. Then there are the smaller ones with rollovers. does this make any sense? there's actually 13 little sounds.

[Code]...

View 3 Replies

ActionScript 2.0 :: LoadSound Starts Fine, Then A Second Starts Replaying Again?

Apr 8, 2006

I've got a site that is using loadSound to play some mp3s and it works fine. however, the sound starts to stream, and then replays itself like a second later. my guess is that its playing faster than the load is going and when it gets to the point where it hasn't loaded enough, it starts to replay it, but i'm not sure that that is the exact problem. my code:

[Code]...

now, i tried making a playTrack function that i can call with setTimeout and i put that in the onLoad in place of track.start(), but that didn't work either (i was hoping to not start playing the track for 3 seconds to give it some time to buffer).

View 1 Replies

ActionScript 2.0 :: Loadsound() Not Working When Movie Is Loaded In Other Movie?

Mar 17, 2009

I'm made a flash movie[main movie 1] where another movie is loading using the "loadMovie()"[this is the movie2] command.my probblem is - when I'm trying to loadsound in to the second movie

Code:
var mySound1:Sound = new Sound(this);
mySound1.loadSound("music.mp3",true);

[code]....

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved