Solved

Hover Over Photos to Enlarge Them on ASP Page

Posted on 2014-03-30
2
348 Views
Last Modified: 2014-03-31
I have an ASP web page that holds ten thumbnail photos.  I want to be able to hover over the thumbnails and have an enlarged photo of each pop up.  I found some code to do this at http://cssdemos.tupence.co.uk/image-popup.htm.  One of the problems I am having is the sample code requires an unordered list of the thumbnails.  This is easy if your photos are statically held in an Images folder.  Mine are dynamic, served to the page inside recordsets; one for thumbnail photos (rsThumbs), and the other for enlargements of the thumbnails (rsLarge).

How can I move through these recordsets and create a <li> tag for each of the ten thumbnail photos and a <span> tag for each of the enlargements that are served?
 
If you follow the above link and see how the process works, it may take less time for you experts to understand my dilemma.  If, on the other hand, someone has an easier or better way to do this, I would love to hear it.

Thanks!!
0
Comment
Question by:shanej
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 500 total points
ID: 39965587
Just use 'response.write' or <%=...%> to put the image file names in the 'src' attributes.
    <!--THE IMAGES ARE PLACED IN AN UNORDERED LIST-->
    <ul class="enlarge"> <!--We give the list a class so that we can style it seperately from other unordered lists-->

    <!--First Image-->
    <li>
    <img src="<% response.write("image01s.jpg") %>" width="150px" height="100px" alt="" /> <!--thumbnail image-->
    <span> <!--span contains the popup image-->
    <img src="<% response.write("image01L.jpg") %>" alt="" /> <!--popup image-->
    <br /><% response.write("Image 1 caption") %><!--caption appears under the popup image-->
    </span>
    </li>

    <!--Second Image-->
    <li>
    <img src="<%="image02s.jpg" %>" width="150px" height="100px" alt="" /> <!--thumbnail image-->
    <span> <!--span contains the popup image-->
    <img src="<%="image02L.jpg" %>" alt="" /> <!--popup image-->
    <br /><%="Image 2 caption" %><!--caption appears under the popup image-->
    </span>
    </li>

    </ul>

Open in new window

0
 

Author Closing Comment

by:shanej
ID: 39967908
I found another solution at http://www.dynamicdrive.com/style/csslibrary/item/css-popup-image-viewer/P20/.  Thanks for your quick response with the limited info I gave you.
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Technology opened people to different means of presenting information, but PowerPoint remains to be above competition. Know why PPT still works today.
It’s a strangely common occurrence that when you send someone their login details for a system, they can’t get in. This article will help you understand why it happens, and what you can do about it.
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…
Learn how to set-up PayPal payment integration in your Wufoo form. Allow your users to remit payment through PayPal upon completion of your online form. This is helpful for collecting membership payments, customer payments, donations, and more.

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question