I've looked on the internet for help but all I find is how to do image switches for links and slideshows. nothing on how to just pull the image from the array and then print it.
this is the image array Im using, all it will display is the broken image icon.
Expand|Select|Wrap|Line Numbers
- //declare image array
- var product = new Array();
- product[0] = new Image();
- product[1] = new Image();
- product[2] = new Image();
- product[3] = new Image();
- product[4] = new Image();
- product[5] = new Image();
- product[6] = new Image();
- product[7] = new Image();
- product[8] = new Image();
- product[9] = new Image();
- //populate image array
- product[0].src = "images/colorpads.jpg";
- product[1].src = "images/glue.jpg";
- product[2].src = "images/highlighter.jpg";
- product[3].src = "images/notecard.jpg";
- product[4].src = "images/pad.jpg";
- product[5].src = "images/pen.jpg";
- product[7].src = "images/pencil.jpg";
- product[8].src = "images/permmarkers.jpg";
- product[9].src = "images/scissors.jpg";
Expand|Select|Wrap|Line Numbers
- document.write("<td class='product_image'>");
- document.write("<img id='"+i+"'/>");
- document.images[i].src = product[i];
- document.write("</td>")
Expand|Select|Wrap|Line Numbers
- document.image("<img src="+product[i]+"/>"
Any help would be nice,
praclarush