Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

loading dynamic images into flash movie

Posted on 2002-04-16
2
Medium Priority
?
215 Views
Last Modified: 2012-05-04
Hello

I'm using flash MX with php script.

I have created a wheel with spinning images.
Every frame has a image.

My question is how can i create a dynamic wheel so that i do not have to specify the images at creation
of my flash movie but call the variables from my php script.

I want to do this also with text.

Is this possible?????
0
Comment
Question by:volvo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 7

Accepted Solution

by:
axis_img earned 300 total points
ID: 6949220
Yes... It is possible. The simplest, and most common method would be to use Flash's loadVariables(url, location [, variables]) function (or maybe it is loadVariablesNum now, depending on whether the target is a number). The URL would be the php script that determines which images to use.

Your php script would determine which images to display, and then print out a single line to the browser. An example of the printout would be:

image1=image1.gif&image2=image7.gif&image3=image4.gif

Your flash movie would then just need to load those images based on the variable name that was passed. So something along the lines of:

var base_image = "http://www.domain.com/images/";
var img1 = base_image + image1;
var img2 = base_image + image2;
...

How you actually decide to implement this is up to you, but this is basically an overview of how it would work.

For more help, look here:

http://www.macromedia.com/support/flash/action_scripts/actions/loadvariables.html

You didn't really specify if you had any PHP specific questions. If you do have questions on how to randomly get the images, etc. then please let us know. In general though, using loadVariables() or loadVariablesNum() is the way to do this.

Good luck.
0
 
LVL 7

Expert Comment

by:axis_img
ID: 6975299
In the future, if you are not going to give an "A" grade, you could at least give an explanation of why it was not worth the A. I do not know you, yet I take the time to try and help you out. The least you could do is give the best grade possible. It doesn't cost you any more to do so, and it shows appreciation for the help.

Have a good day...
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo‚Ķ
This article discusses four methods for overlaying images in a container on a web page
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question