My Images are too large, so I will cut them way down
What is wrong with my code
snippet+++++++
var myImgs=document.getElementsByName("escoImg");
var numImgs=myImgs.length;
/* area of my question the below if statement */
if(myPtr)//true means previous button pushed
{
myImgs.reverse();//reverse the array does NOT WORK
}
//end of question area
for(var x=0;x<numImgs;x++)
{
if(myImgs[x].style.display=="block")
{
myImgs[x].style.display="none";
document.forms[2].elements[0].value=++x;
break;
}
}
if(document.forms[2].elements[0].value==myImgs.length)
document.forms[2].elements[0].value=0;
myImgs[document.forms[2].elements[0].value].style.display="block";
end snippet+++++++
it captures the correct elements. then if I want to hide the shown element
it works
I then can show the desired element.
But if I reverse the array BANG the hole thing dies WHY?
What is wrong with my code???
http://escokitchens.com/learning/kitcheView.html
--
Totus possum, totum Deum.
Totus ero, totum meum.
WSW