1
我在想如何在图像上使用图像映射作为jQuery可拖动图像的句柄。这是我到目前为止。使用图像映射作为jQuery UI的句柄Draggable
JS
$('.stickyleave').draggable({
containment:'#stickyleave-main',
handle: "#" + $(e).find('img').attr('usemap') + " area",
start:function(e,ui){
ui.helper.css('z-index',++$.zIndex);
}
});
HTML
<div class="stickyleave" />
<img usemap="#image_map" src="' . $upload_dir['baseurl'] . '/' . $style[0] . '.png" />
<map name="image_map" id="image_map">
<area shape="poly" coords="4,27,27,12,45,2,65,1,83,11,91,17,99,29,89,47,60,56,39,52"/>
</map>
</div>
,但它只是将无法正常工作。任何建议都会有所帮助。由于
我曾试图修复这一点,但无济于事。原来,愚蠢的铬缓存坏代码,所以它不工作,实际上它是。非常感谢!!! – brenjt 2012-04-19 16:16:08