Hi,
I’m wondering how to display my slideshow captions. Setting ALT & TITLE tags below works fine, but I get an error when I try to change the value of the TextArea Object.
Please let me know if there is a better HTML object out there that I can use to display text from Javascript.
Here is the code.
myPix = new Array(“
myCaption = new Array(“Chuck TEaches the kids”,”TEst”)
thisPic = 0
imgCt = myPix.length -1
function chgSlide(direction) {
if (document.images) {
thisPic = thisPic + direction
if (thisPic > imgCt) {
thisPic = 0
}
if (thisPic < 0) {
thisPic = imgCt
}
document.myPicture.src=myPix[thisPic]
document.myPicture.alt=myCaption[thisPic]
document.myPicture.title=myCaption[thisPic]
document.myText.value=myCaption[thisPic]
}
}
As you can see, I’m setting the ALT & TITLE tags of the IMG to the caption string successfully. However I’d like to set a textarea or other label below the img as well. Would appreciate any help with how to reference the apporpriate HTML object.
I’d like to use a textarea, but this doesn’t seem to work
<TEXTAREA NAME=myText>abcd</TEXTAREA>