SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Addict eJM's Avatar
    Join Date
    Feb 2004
    Location
    teh Ether
    Posts
    221
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Change linked image when clicking on it.

    I have a list of links, each one beginning with a linked image that takes the visitor who clicks it to a particular page. When they click the back button, they are presented with the same list, but may have forgotten where they are in the list. I would like the image they just clicked on to change to one of a different color so that they can see where they were on the list when they return to it.

    These are the 2 images that will be linked to a document:

    Here is the current code and CSS, which does not use the second image:
    Code:
    .inlineimg { vertical-align: middle; }
    
    <a href="address_of_document"><img class="inlineimg" src="imgdir/firstnew.gif" alt="" border="0" /></a>
    I am not concerned about whether the image changes when hovered, only when clicked. Can you help me with the CSS and HTML?

    Thank you,

    Jim

  2. #2
    He's No Good To Me Dead silver trophybronze trophy stymiee's Avatar
    Join Date
    Feb 2003
    Location
    Slave I
    Posts
    23,426
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)
    You'll need JavaScript and cookies to do this. Moving this to the JavaScript forum.

  3. #3
    SitePoint Addict eJM's Avatar
    Join Date
    Feb 2004
    Location
    teh Ether
    Posts
    221
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The site does use JavaScript and cookies. It also uses ajax, if that will help.

    Thanks.

  4. #4
    SitePoint Addict eJM's Avatar
    Join Date
    Feb 2004
    Location
    teh Ether
    Posts
    221
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Any help for this would be appreciated.

    Jim


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •