Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

alter disjointed rollover code to accomodate database driven images

Status
Not open for further replies.

ringadeal

Technical User
Jan 16, 2008
67
0
0
US
The effect I would like to achieve is that by clicking on a repeat region thumbnail image (first code block) the larger version of the same selected image is viewed concurrently in a different portion of the page(second code block)
Code:
<td ><% 
While ((Repeat1__numRows <> 0) AND (NOT images.EOF)) 
%>
                    <a href="javascript:;" onmouseover="MM_swapImage('largeimage','','largeimage',1)" onmouseout="MM_swapImgRestore()"><img src="imagescript.asp?path=<%=(images.Fields.Item("url_img").Value)%>&Width=36" name="smallimage" border="0" id="smallimage" /></a>
                    <% 
  Repeat1__index=Repeat1__index+1
  Repeat1__numRows=Repeat1__numRows-1
  images.MoveNext()
Wend
%></td>
Code:
<td ><img src="imagescript.asp?path=<%=(images.Fields.Item("url_img").Value)%>&Width=250" name="largeimage" id="largeimage" /> </td>
 
look towards:
1. "passing url variable"
or
2. passing variables with hidden form fields

in essence it is 'master-detail' where on the target (detail page) you would filter the record set based on what you decide above (1 or 2)

All the best!

:-------------------------------------:
Do the DW »|MostarNetworks|
 
You cannot repeat the id 'smallimage' for each of your rollovers. An id must be unique in a page.

Try changing your id to something like:
Code:
name="smallimage<%Repeat1__index%>" border="0" id="smallimage<%Repeat1__index%>"

or something to that effect.

Greg
People demand freedom of speech as a compensation for the freedom of thought which they seldom use. Kierkegaard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top