Getting Hover to work on IE7 with other tags than anchor

January 12, 2008 at 1:53 pm (How it's Done: Tips and Snippets?)

Before IE7, hover used to exclusively work with the anchor tag. On IE7, unless you make your HTML page follow a strict html4/xHTml1.0/1.1 dtd it will still not work… So you actually need to add this to the top of your html page:

<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 4.01//EN” “http://www.w3.org/TR/html4/strict.dtd”>

a more detailed post regarding this is in:

http://www.bernzilla.com/item.php?id=762

Voila!

Post a Comment