1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

CSS Single Image Sliding Doors and Rollover

Discussion in 'CSS' started by feha, Aug 17, 2008.

  1. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #21
    Well, little too simple since it only targets LI, and /fail/ because it requires an additional class (part of why I dislike suckerfish)

    Which is why I just use Peterned's csshover2.htc
    http://www.xs4all.nl/~peterned/csshover.html

    Which also implements :focus under legacy IE. Using this (I usually load it in my CSS behind a * html hack) you can write a fully standards compliant page, and only IE6/earlier users get the script - and you are no longer limited to just using LI as you can now :hover or :focus ANYTHING.
     
    deathshadow, Aug 22, 2008 IP
  2. feha

    feha Active Member

    Messages:
    1,005
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    80
    #22
    Yes, you are right "anything hover" is more flexible ...
    I think the css has to be built that way if JS disabled the menu be expanded list.
    This would require anyway some JS that "hides" sub menus when JS is active (for all browsers) just to avoid
    display:none; ...
     
    feha, Aug 23, 2008 IP
  3. feha

    feha Active Member

    Messages:
    1,005
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    80
    #23
    Here is my simple css version for single level dropdown, no *hacks ...
    Adding JS can support IE6 ...
    If no css should show "normal" menu list ...

    http://www.vision.to/simple-css-one-level-dropdown-menu.php

    Still beta it uses positioning instead of display:none;

    Will work on "sliding doors" version based on this simple one ...
    But first must fix some problems and need to adapt top menu for variable width ...
     
    feha, Aug 23, 2008 IP