www.webdeveloper.com
Results 1 to 7 of 7

Thread: CSS div hover - why doesn't this work in IE7?

  1. #1
    Join Date
    Oct 2005
    Posts
    59

    CSS div hover - why doesn't this work in IE7?

    http://www.littleduck.com/test.html

    This works in FF and Safari (for PC and Mac), but not in IE7. It's just a simple rollover ... any tips?

    (The source code is viewable at the site, if that's OK!)

    Thank you!

  2. #2
    Join Date
    Aug 2007
    Location
    New Jersey, US
    Posts
    1,779
    I'll guess that it's one of two things:

    1 - no doctype (you need one)

    2 - IE doesn't support hover on DIVs (test it by trying different, more simple effects on divs)

  3. #3
    Join Date
    Feb 2006
    Posts
    198
    use some javascript and an onmouseover() event to handle changing style of the div u need..

  4. #4
    Join Date
    Oct 2005
    Posts
    59
    1 - no doctype (you need one)
    Holy crap, thank you. Adding doctype worked. I was just doing a quick 'n dirty ... in the future I'll remember not to do them THAT quick 'n dirty.

  5. #5
    Join Date
    Aug 2007
    Location
    New Jersey, US
    Posts
    1,779
    awesome - glad it worked out...

  6. #6
    Join Date
    Dec 2008
    Posts
    1

    re:add doctype

    wow, it does work with just adding doctype!

    pretty cool


  7. #7
    Join Date
    Jul 2006
    Posts
    207
    Adding the doctype ensures that strict mode is enabled, as opposed to the original mode; quirks mode.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

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



Recent Articles