我使用的是:
MAP.area = $( #centre_map area, #map ol li );
MAP.area.hover(function() {
// Add active classes
// Load content
load_map_activity($( body ).attr( id ), $(this).attr( class ));
}, function() {
// Remove active classes
})
<div id="map">
<img src="<?php echo base_url(); ?>images/bristol_map.png" alt="bristol map" usemap="#centre_map" />
<map name="centre_map" id="centre_map">
<area shape="poly" coords="179,95,188,87,187,53,181,48,54,29,41,38,37,53,39,77,44,87" href="#" class="paintball" alt="Paintballing" />
</map>
<ol>
<li class="paintball"><a class="marker paintball" href="#" title="Paintballing">1</a></li>
</ol>
Rory McCrossan 我将试图这样做,但我担心,因为主线被放在图像地图区一带,当 mo被移至 anchor(尽管我们仍位于地图区)时,会再次发出 h。