[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

2 random swf

Posted on 2005-04-27
1
Medium Priority
?
223 Views
Last Modified: 2010-05-18
Hello,

I have the following code that I'm trying to use to randomize 2 swfs inside a html page.

The code below I'm putting it on the first movie of 2 total movies (header.swf and header2.swf) *are the movie that I'm trying to randomize


code:

------------------------------------

numberOfMovies=2
movieNumber = Math.ceil(Math.random()* numberOfMovies);
movieToBeLoaded = "header" + movieNumber +".swf";
trace (movieToBeLoaded);
loadMovieNum("header" + movieNumber + ".swf", 0)

---------------------------------------------

I've placed this code on "header.swf" and when I preview the movie it actually shows "header2.swf" and when I preview the html...only "header2.swf" shows.

Thanks
0
Comment
Question by:johanwilches
1 Comment
 
LVL 30

Accepted Solution

by:
GrandSchtroumpf earned 1500 total points
ID: 13880625
your first file needs to be "header1.swf" and not "header.swf"
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Most of the sites are being standardized with W3C Web Standards. W3C provides lot of web standard services to the web. They have the web specification, process and documentation for all the web standards. You can apply HTML, CSS and Accessibility st…
I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).
Suggested Courses

825 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