Well, images can do onclick, so, not sure on the <a> needed for the
linking, seems to me you can do all this using an onclick on the images, I
use the removeAttribute() in order to remove the 'href' and thus making it
not-hyperlink, however, you do all that with a function onclick of the
image and give the image style="cursor: pointer" to have the mouse change
as if it was a link, as for addressing the images, you can just give them
associative names, like name="image1" name="image2" and use the
document.images collection to iterate or access them, as in for
(i=0;i<3;i++) {.... document.images['image'+i].src='ANOTHERFILE.png'; or
such.
Danny
On Sun, 26 Jun 2005 12:41:38 -0700, inonzuk <in*****@hotmail.com> wrote:
thanks for the answer, another question is :
1)how can I start with image 1 clickable and image 2 unclickable, and
only after I click image 1 -> image 2 becomes clickable. (i.e.
starting with href empty on image 2 and setting its value when image 1
is clicked).
2)I want to change the image src when the image in unclickable. what is
the correct way to check it (I want to do a "if" condition ... if (href
is empty for that picture) change the src to unclickable image).
I want to do a function "onClick = doThis()"
function doThis(){
if (href is empty){
change the href to clickable link
change the image src to clickable button
}else{
change to empty href
(document.images['b_ru*les'].parentElement.removeAttr*ibute('href')")
change the image src to unclickable button
}
}
--
Using Opera's revolutionary e-mail client:
http://www.opera.com/mail/