Ask a Question related to Macromedia Dynamic HTML, Design and Development.
-
kelly @ herco #1
Switch Images
Where can I find the script which switches images upon page refresh?
Or, what is tha name of this particular script?
I looked on Dynamic Drive but didn't see anything or I just don't know what
it's called.
Thanks!
Text:beer;;)
kelly @ herco Guest
-
Trouble with -T switch
Hi everybody, I'm having trouble with setting the path to my sendmail program when using the -T switch. It's a simple script that creates a from,... -
Switch to 12" G4 - ?'s
I am looking for an ultraportable to do powerpoint and word on, and take on the road for presentations, It must work flawlessly with my desktop... -
Trying to use a here doc within a switch
I'm trying to use here docs within a switch to output html. The code below works (i.e. prints a Foo1 headline below my tab graphic) but if I take... -
Computer won't switch on
Hi -- I have a 7013-595 running AIX 5.1. It doesn't get used very often; the last time I used it was almost a month ago. Back then, it worked... -
Switch Versions
How do i chnage in MX from MX to 4 and visa versa? -
kelly @ herco #2
Switch Images
Where can I find the script which switches images upon page refresh?
Or, what is tha name of this particular script?
I looked on Dynamic Drive but didn't see anything or I just don't know what
it's called.
Thanks!
Text:beer;;):confused;
kelly @ herco Guest
-
mzanime.com #3
Re: Switch Images
Here's the javascript code you would need to do what you want to do:
<script language="JavaScript" type="text/javascript">
<!--
var quote = new Array(
"<img src=\'images/pic1.gif\' alt=\'picture\'>",
"<img src=\'images/pic2.gif\' alt=\'picture\'>",
"<img src=\'images/pic3.gif\' alt=\'picture\'>",
"<img src=\'images/pic4.gif\' alt=\'picture\'>",
"<img src=\'images/pic5.gif\' alt=\'picture\'>"
);
document.write(quote[Math.floor(Math.random()*quote.length)]);
// -->
</script>
A couple of things to keep in mind. No comma after the last image. Any
code inside the quotes that contains a apostrophe, or quote must be
escaped. (see above) And its a good idea to make sure all your
rotating images are the same size. Otherwise your layout can get kinda
ugly.
This script will load a random image each time a user visits your
page, nothing more.
mzanime.com Guest
-



Reply With Quote

