Alright. Would someone please help me with this.
I have been tinkering with it for 7 hours straight with absolutely zero headway being made.
My goal: to create a javascript image array that will allow the user to navigate various images without changing the url: also, without preloading the images.
What I have which doesn’t work:
[code=php]
var comics=new Array()
comics[0]=new Image(638, 825)
comics[0].src=”/comics/comic1.jpg”
comics[1]=new Image(638, 825)
comics[1].src=”/comics/comic2.jpg”
comics[2]=new Image(638, 825)
comics[2].src=”/comics/comic3.jpg”
comics[3]=new Image(638, 825)
comics[3].src=”/comics/comic4.jpg”
comics[4]=new Image(638, 825)
comics[4].src=”/comics/comic5.jpg”
comics[5]=new Image(638, 825)
comics[5].src=”/comics/comic6.jpg”
comics[6]=new Image(638, 825)
comics[6].src=”/comics/comic7.jpg”
comics[7]=new Image(638, 825)
comics[7].src=”/comics/comic8.jpg”
comics[8]=new Image(638, 825)
comics[8].src=”/comics/comic9.jpg”
comics[9]=new Image(638, 825)
comics[9].src=”/comics/comic10.jpg”
comics[10]=new Image(638, 825)
comics[10].src=”/comics/comic11.jpg”
comics[11]=new Image(638, 825)
comics[11].src=”/comics/comic12.jpg”
document.write(comics[11])
yes, I realize document.write is not the proper function, but it is the only one that when I put in works at all, and all it does is output [object]. I tried document.images(comics[11]).src, something that I was led to believe was the solution, and got no output whatsoever.
Somebody please help because I have scoured the internet trying to answer my question and there has been nothing that advanced me.