Css hover one id and change another?

Discussion in 'HTML & Website Design' started by fadetoblack22, Sep 17, 2009.

  1. #1
    I have the following list code which parses some rss. When I hover over each li, the lirss-forum id changes the background color, however the text is then too dark. How can I make the text color of the arss-forum id change when lirss-forum is hovered?

    $title = $item['title'];
    $url = $item['link'];
    $description = $item['description'];
    print "<li id='lirss-forum'>";
    print "<a href=$url id='arss-forum'>$title</a>";
    print "<p id='prss-forum'>$description</p>";
    print "</li>";
     
    fadetoblack22, Sep 17, 2009 IP
  2. skript

    skript Active Member

    Messages:
    81
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    93
    #2
    #lirss-forum:hover #arss-forum { color: #HEX_COLOR }
    Code (markup):
    Unfortunately IE versions under 7 don't support the :hover pseudo class for other elements than <a>
     
    skript, Sep 17, 2009 IP