(simple?) DOM problem
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.javascript archive

(simple?) DOM problem

From: bmgz <bmg2x@yahoo.com>
Date: Wed Feb 08 2006 - 12:16:01 CET

I have a simple DHTML gallery:

<script>
viewPhoto(thumb){
function viewPhoto(thumb){
   document.getElementById('mainPhoto').src=thumb.href;
   return false;
}
</script>

...
<body>
<a onclick="javascript:return viewPhoto(this);" href="whatever"><img src="thumbnail" /></a>
</body>
...

I want the currently viewed images' thumbnail to have a nice thick red-border.
I have managed to do this slap dash, but I had a better way, My only problem is
that I need to find out the DOM Array value of the thumbnail object (ie the "thumb" param)
Is this possible?
Received on Mon May 1 03:09:50 2006