Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q642 How can I make a thumbnail image selected show a full-size image in another table cell on the same page?

irt.org | Knowledge Base | JavaScript | Image | Q642 [ previous next ]

Q642 How can I make a thumbnail image selected show a full-size image in another table cell on the same page?

Try something like:

<SCRIPT LANGUAGE="JavaScript"><!--
function show(name,src) {
    if (document.images)
        document.images[name].src = src;
}
//--></SCRIPT>

<TABLE>
  <TR>
    <TD>
      <A HREF="javascript:show('myimagename','myimage.gif')"><IMG SRC="smallmyimage.gif" WIDTH="50" HEIGHT="50" BORDER="0"></A>
    </TD>
  </TR>
  <TR>
    <TD>
        <IMG SRC="blank.gif" NAME="myimagename" HEIGHT="200" WIDTH="200">
    </TD>
  </TR>
</TABLE>

Feedback on 'Q642 How can I make a thumbnail image selected show a full-size image in another table cell on the same page?'


Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 6th July 2009. Maintained by: Martin Webb and Michel Plungjan
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2009 irt.org, All Rights Reserved.