sophielois
Technical User
Hi guys,
Could someone give me some advice how to use the following script so that it will randomly change a background image.
this is the script im using that randomly changes the image being displayed when the page ios loaded.
In the body of the page i do this
Is it possible to apply it to the background image of a table, something like this:
This does not work, but im sure it is possible but i really dont know how to do it.
I've still very much got my L-plates on when it comes to javascript.
really appreaciate any help offered.
Thanks
Soph
Could someone give me some advice how to use the following script so that it will randomly change a background image.
this is the script im using that randomly changes the image being displayed when the page ios loaded.
Code:
<SCRIPT LANGUAGE="VBScript">
<!--
Sub Window_OnLoad
Dim arrPic, intPic
Randomize
intPic = Fix(Rnd * 5)
arrPic = Array("img1", "img2", "img3", "img4", "img5")
Show.src = "newimages/" & arrPic(intPic) & ".jpg"
End Sub
-->
</SCRIPT>
In the body of the page i do this
Code:
<IMG NAME="Show" border=0 alt="show this one">
Is it possible to apply it to the background image of a table, something like this:
Code:
<table width="718" height="282" border="0" align="center" cellpadding="0" cellspacing="0" bordercolor="#6699FF" background="Show">
This does not work, but im sure it is possible but i really dont know how to do it.
I've still very much got my L-plates on when it comes to javascript.
really appreaciate any help offered.
Thanks
Soph