Aaron
Aaron

Reputation: 541

Passing a variable from PHP to a Flash SWF?

I'm trying to pass the file name of an image upload PHP script into Flash's UILoader component. So when a user uploads their image, the file name of the file is passed to flash so that the image displays within the Flash UILoader application.

Here's the PHP variable I'm trying to pass:

$filename= '';

And here's where Flash's UILoader gets it's source (ActionScript 3.0):

uiLoader.source = "freshly uploaded file.jpg ($filename)?";

So if anybody has any expert advice on how I'd going about doing this, that would be excellent. Thanks a lot in advance!

Aaron

Upvotes: 0

Views: 748

Answers (1)

Ashley
Ashley

Reputation: 1489

Try using FlashVars. You can then pass variables to the SWF when it's embedded.

Upvotes: 1

Related Questions