SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Enthusiast bernadette's Avatar
    Join Date
    Aug 2007
    Posts
    46
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    is there's a way to make the "display" property work for IE 6?

    for pop up menus
    I'm trying to avoid java
    so i used pure css with divs only

    div.menu div.list {display:none;}
    div.menu:hover div.list { display:block;
    background-color:#666666;}



    Is there's a hack makes it work?

    Thanks

  2. #2
    SitePoint Wizard bronze trophy DaveWoods's Avatar
    Join Date
    Dec 2004
    Location
    Derbyshire - UK
    Posts
    2,651
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    IE6 and below only allow :hover to work on <a> so you'll need JavaScript (don't confuse it with Java as they're completely different).

    Without having seen your code or what this is going to be used for, you could potentially apply this to a link and get around it that way in IE6 although you'll need to consider potential problems with accessibility as well as making sure that search engines can spider these links.

  3. #3
    SitePoint Enthusiast bernadette's Avatar
    Join Date
    Aug 2007
    Posts
    46
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I use a code like the one here :
    http://surguy.net/menu/index.html

    if i assumed using (csshover.htc)
    would the IE read the "display" property ?

  4. #4
    SitePoint Wizard
    Join Date
    Jul 2003
    Location
    Kent
    Posts
    1,921
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    google on son of suckerfish. That is widely used and works.

  5. #5
    In memoriam gold trophysilver trophybronze trophy Dan Schulz's Avatar
    Join Date
    May 2006
    Location
    Aurora, Illinois
    Posts
    15,476
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Actually in this case I'd use a .htc file instead of Suckerfish.

  6. #6
    CSS & JS/DOM Adept bronze trophy
    Join Date
    Mar 2005
    Location
    USA
    Posts
    5,482
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    whatever:hover
    Suckerfish :hover

    From http://surguy.net/menu/highlightCurrent.js Someone is a bit confused:
    // Setting class is needed for Mozilla compatibility - className appears to be correct
    // according to the DOM spec
    links[i].setAttribute("class", "current");
    links[i].setAttribute("className", "current");
    We miss you, Dan Schulz.
    Learn CSS. | X/HTML Validator | CSS validator
    Dynamic Site Solutions
    Code for Firefox, Chrome, Safari, & Opera, then add fixes for IE, not vice versa.


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
  •