Hello!

As the Lightbox image display utility doesn't work with 'area' image maps (out of the box, anyway, and I can't rely on modified installations), I am implementing a pseudo image map using positioned, block-level links that sit over the image regions.

I'm doing this with divs located immediately after the image tag, set to position: absolute so they're out of the text flow, but positioned relatively using margins. Inside the divs are link tags with display:inline-block and with 100% width and height. This seems to satisfy most browsers, including IE 6, but not IE 7.

In IE 7, the link is not clickable, although putting a border on it shows that it is still positioned correctly. Further investigation reveals that it is because IE 7 doesn't appear to be capable of maintaining a transparent clickable area over existing page content.

Is anyone aware of a workaround to this problem? Or, alternatively, does anyone have any different suggestions for providing image map functionality that is compatible with Lightbox?

Many thanks in advance!

Sample code follows:


HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>

	<title>Test</title>
	
</head>

<body>
    
    <h1>Working link</h1>
    <p><em>Link is in an absolutely positioned div, with inline-block and 100% width and height.  It is out of content flow, but with no content behind it. Works as expected.</em></p>
    
    <div style="width: 50px; height: 50px; position: absolute;"><a href="http://example.com" style="display: inline-block; border: 1px solid red; width: 100%; height: 100%;"></a></div>
    
    <!-- Blank spacer -->
    <div style="height: 50px;"></div>

    <h1>Bug demonstration</h1>    
    <p><em>Same link markup, but now has content behind.  Link no longer functions.</em></p>
    
    <div style="width: 50px; height: 50px; position: absolute;"><a href="http://example.com" style="display: inline-block; border: 1px solid red; width: 100%; height: 100%;"></a></div>
    
    <!-- Content underneath absolutely positioned block link -->
    <p>Ilit adipsusto hendrerit velisl velenis est sismolore quatums phasellus; velisit eugue placerat nostra tin aliquet. Vulla odio fames vel. Eugiam incipis nisit, tortor henisi eleifend conubia faciliquis prate, adion habitant eumsandre. Ex enibh exercillaore deliqui msandre nullandigna odigna volesed facipsum, vent feugiamet adignit. Volor pharetra autatie, turpis rutrum habitasse vendre acipit ullut, volobore enim molor.</p>


    <h1>One, non-viable workaround</h1>    
    <p><em>Supply a background color on the link or the div container. Not a viable solution though, as link must be transparent.</em></p>
    
    <div style="width: 50px; height: 50px; position: absolute; background: #fee;"><a href="http://example.com" style="display: inline-block; border: 1px solid red; width: 100%; height: 100%;"></a></div>
    
    <!-- Content underneath absolutely positioned block link -->
    <p>Ilit adipsusto hendrerit velisl velenis est sismolore quatums phasellus; velisit eugue placerat nostra tin aliquet. Vulla odio fames vel. Eugiam incipis nisit, tortor henisi eleifend conubia faciliquis prate, adion habitant eumsandre. Ex enibh exercillaore deliqui msandre nullandigna odigna volesed facipsum, vent feugiamet adignit. Volor pharetra autatie, turpis rutrum habitasse vendre acipit ullut, volobore enim molor.</p>

</body>
</html>