Embedding Flash in PHP page

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
methodize
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2010 3:14 am

Embedding Flash in PHP page

Post by methodize »

This is my first post on the DevNetwork Forums, since I rarely run into PHP problems (ha, yeah right.)

Let's get down to business.
So, I'm just about done my fancy new Concrete5 CMS website, and there is ONE thing that I just cannot figure out.

I have a flash file on my page that will just not co-operate with me, and I'm going to get grey hair over it (not that I don't already have grey hair!)

The file: It is a flash music player that draws from a folder called "MP3s" using an XML file. Check it out here: http://www.blazing-media.com/strongman/test to see it working just fine.

I used c5 to insert it. The "loading" circle just spins, but no music starts. http://www.blazing-media.com/strongman/... is my development page. If you take a look at the source, and actually follow the src, you'll see that if you open it, it is working just fine. Just when it is embedded it doesn't work.

ANY help here would be so, so appreciated. Trust me, I'm going bananas here.

I took some screenshots of the source & of the FTP, you'll find those attached.

Thanks in advance!
Attachments
source_screenshot.jpg
source_screenshot.jpg (120.81 KiB) Viewed 427 times
ftp_screenshot.jpg
ftp_screenshot.jpg (116.99 KiB) Viewed 427 times
minorDemocritus
Forum Commoner
Posts: 96
Joined: Thu Apr 01, 2010 7:28 pm
Location: Chicagoland, IL, USA

Re: Embedding Flash in PHP page

Post by minorDemocritus »

First off... he's really good! Gotta love blues with a lot of folk influence.

The <object> and <embed> tags are commented out on the http://www.blazing-media.com/strongman/ page... I think that might have something to do with it :mrgreen:

Blues like that makes me want to party! :drunk: :drunk:
minorDemocritus
Forum Commoner
Posts: 96
Joined: Thu Apr 01, 2010 7:28 pm
Location: Chicagoland, IL, USA

Re: Embedding Flash in PHP page

Post by minorDemocritus »

I also notice that on the /strongman/test/ page, when you hover over the player, it shows the songs, and you can select them. BUT this only works for the first 4 songs... Mean to Me isn't showing up. It's too bad, cause that's a kick ass song!
methodize
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2010 3:14 am

Re: Embedding Flash in PHP page

Post by methodize »

minorDemocritus wrote:First off... he's really good! Gotta love blues with a lot of folk influence.

The <object> and <embed> tags are commented out on the http://www.blazing-media.com/strongman/ page... I think that might have something to do with it :mrgreen:

Blues like that makes me want to party! :drunk: :drunk:
He does make great music, great guy too.
The parts that are commented out are actually for older code that was in the header image rotator, not the music player. The Music player embed code is the attached image above.

Any other suggestions? I'm desperate here!
User avatar
Grizzzzzzzzzz
Forum Contributor
Posts: 125
Joined: Wed Sep 02, 2009 8:51 am

Re: Embedding Flash in PHP page

Post by Grizzzzzzzzzz »

Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: songlist.xml
at local.display::MP3Player/startXML()
at Function/http://adobe.com/AS3/2006/builtin::apply()
at SetIntervalTimer/onTimer()
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()
might be an issue


check where the file 'songlist.xml' is located, and also where it should be located
methodize
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2010 3:14 am

Re: Embedding Flash in PHP page

Post by methodize »

Grizzzzzzzzzz wrote:
Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: songlist.xml
at local.display::MP3Player/startXML()
at Function/http://adobe.com/AS3/2006/builtin::apply()
at SetIntervalTimer/onTimer()
at flash.utils::Timer/_timerDispatch()
at flash.utils::Timer/tick()
might be an issue


check where the file 'songlist.xml' is located, and also where it should be located
Before, the MP3Player.as file was looking in just "songlist.xml". To be sure that it was finding it properly, I made the URL absolute. Can you do that same troubleshooting and see if it is returning that same error?
Here's how it's set up now:
[syntax]public static const XML_PATH: String = "http://www.blazing-media.com/strongman/ ... nglist.xml";
[/syntax]
minorDemocritus
Forum Commoner
Posts: 96
Joined: Thu Apr 01, 2010 7:28 pm
Location: Chicagoland, IL, USA

Re: Embedding Flash in PHP page

Post by minorDemocritus »

methodize wrote:The parts that are commented out are actually for older code that was in the header image rotator, not the music player. The Music player embed code is the attached image above.
In the working /test/ example, you have this code:

Code: Select all

<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" width="194" height="97" id="SS_audio_194x97" align="middle">
	<param name="allowScriptAccess" value="sameDomain" />
	<param name="allowFullScreen" value="false" />

	<param name="movie" value="SS_audio.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#ffffff" />	<embed src="SS_audio.swf" quality="high" bgcolor="#ffffff" width="194" height="97" name="SS_audio_194x97" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
	</object>
Don't you need that (or something like it) on the page itself? You're doing it different between the test and the live page... at least my browser thinks so. In page info for /test/, I see SS_audio.swf is type 'embed'... but in the live page, it's type 'object'.
methodize
Forum Newbie
Posts: 7
Joined: Sat Apr 10, 2010 3:14 am

Re: Embedding Flash in PHP page

Post by methodize »

For anyone looking at this topic having the same problem.

I found out that the SWF file was looking for the XML in the wrong place, and thanks to Safari's Activity tool (window-->activity) I was able to see the exact path it was looking for, so I just dropped the SWF file neatly in there.
Post Reply