SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast
    Join Date
    Aug 2003
    Location
    uk
    Posts
    55
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Possible to hover over one object & format another object?

    Hi, I have a couple of images in cells of a table, as well as some text in another table cell.

    I want the text to change colour when I hover over an image. Is this possible? Can CSS change the formatting of an object that it doesn't directly apply to?

    Also, how can I make the whole table clickable and point to the same link? I tried the code below but only the border of the table is clickable.

    ---------------------------
    <a class="class1" href="myLink.html">
    <table>
    <tr>
    <td><img src="image1.jpg"></td>
    </tr>
    <tr>
    <td>This is my content text.</td>
    </tr>
    <tr>
    <td><img src="image2.jpg"></td>
    </tr>
    </table>
    </a>
    ---------------------------

    Any ideas?

    Thx,
    May

  2. #2
    \m/\m/ karinne's Avatar
    Join Date
    Dec 2002
    Location
    Aylmer, QC, Canada
    Posts
    409
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    First off you can't make a table a link so... that's not gonna work

    Concerning your mouseover... the only mouseover that I know of (a part from using Javascript for it) is to shade off an image... but that only works in IE. You can see it in action on my site http://www.karinnelegault.com/en/portfolio/

    Code:
    <img src="image.gif" style="filter:alpha(opacity=50)" onmouseover="this.filters.alpha.opacity='100'" onmouseout="this.filters.alpha.opacity='50'">
    hth

  3. #3
    SitePoint Addict artemis's Avatar
    Join Date
    Sep 2003
    Location
    London
    Posts
    295
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    If you have dreamweaver you can use the show/hide layers option in the behaviours panel, but it does mean having to use layers instead of tables and it can get a bit compolicated, sorry I can't give you a hard coded answer


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
  •