Mouse Over:

Posted on 2005-04-06
Last Modified: 2010-04-25
Hi everyone,

I have a list of items on my web site:

item1   item2   item3  Image1

These all items are link. what I am trying to do that whenever mouse is over the item1 - like to show the item1's image in Image1. same for item2, item3.

How do I do that?

Thanks all.

I am very basic with script.
Question by:neonlights
    LVL 23

    Accepted Solution

    Lets say this is your image

    <img name="img1" src="img.gif">

    and here is your Link

    <a href="item2.asp" onMouseover="document.images[img1].src='item1_IMG.gif'" onMouseout="document.images['img1'].src='img.gif'">Item1</a>

    for item3

    <a href="item3.asp" onMouseover="document.images[img1].src='item3_IMG.gif'" onMouseout="document.images['img1'].src='img.gif'">Item3</a>

    - so we gave our main image a name
    - on Mouseover we referenced to that image, and supplied the path of new image
    - on Mouseout we default the main image back to its orignal state.

    Author Comment

    Amazing, Now, I want to learn .... great solution - Thank you very much again. I am learning...

    Thanks again

    Featured Post

    Highfive + Dolby Voice = No More Audio Complaints!

    Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    Free website editor 10 546
    Unable to Connect Via FTP 109 1,168
    ColdFusion dropdown multiple select question 3 574
    Remove LF from html text 5 407
    For those who don't know, Adobe Dreamweaver is a popular commercial web editor that enables you to design, build and manage complex websites. The editor is a WYSIWYG (What You See Is What You Get) web editor, which means that you can create your web…
    I still run into .cgi files every now and then. In some instances, I actually prefer the simplicity of a .cgi script to other options. Since I use DreamWeaver extensively, what I needed was a way to open .cgi scripts in Dreamweaver. And I wanted to …
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    755 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

    Need Help in Real-Time?

    Connect with top rated Experts

    21 Experts available now in Live!

    Get 1:1 Help Now