我发现基于CSS的HTML Imagemaps可以让你做一些整洁的事情,如设置热点的风格基于:悬停,点击,访问等。但你只限于使用方块&矩形。HTML Imagemaps常规VS CSS基于
但我不认为你可以在标准的HTML图像映射中做到这一点。 但标准的HTML图像地图的好处是,你可以多边形,圆形。
这个限制是否正确?
样品基于CSS的图片映射代码
<div class="imgmap_css_container" id="SeatingChartMap"><a style="position: absolute; `top: 396px; left: 565px; width: 20px; height: 43px;" alt="A: 1: 1" title="A: 1: 1" href="11" target="" ><em>A: 1: 1</em></a><a style="position: absolute; top: 395px; left: 541px; width: 19px; height: 45px;" alt="A: 1: 2" title="A: 1: 2" href="12" target="" ><em>A: 1: 2</em></a><a style="position: absolute; top: 392px; left: 516px; width: 21px; height: 47px;" alt="A: 1: 3" title="A: 1: 3" href="13" target="" ><em>A: 1: 3</em></a><a style="position: absolute; top: 392px; left: 492px; width: 22px; height: 47px;" alt="A: 1: 4" title="A: 1: 4" href="14" target="" ><em>A: 1: 4</em></a><a style="position: absolute; top: 390px; left: 469px; width: 20px; height: 48px;" alt="A: 1: 5" title="A: 1: 5" href="15" target="" ><em>A: 1: 5</em></a><a style="position: absolute; top: 387px; left: 442px; width: 24px; height: 48px;" alt="A: 1: 6" title="A: 1: 6" href="16" target="" ><em>A: 1: 6</em></a></div>`
样本标准HTML图片映射代码
<img src="rexall_place-seating-chart1561-791.gif" USEMAP="#NotNamed" BORDER=0>
<map name="NotNamed">
<area shape="poly" coords="346,93,339,155,355,158,375,92,347,92" href="2" alt="" title="">
<area shape="rect" coords="305,95,332,152" href="1" alt="" title="">
<area shape="rect" coords="201,92,234,153" href="433" alt="" title="">
<area shape="rect" coords="237,92,266,154" href="4343" alt="" title="">
<area shape="rect" coords="272,91,300,154" href="32" alt="" title="">
<area shape="rect" coords="186,317,226,373" href="221" alt="" title="">
<area shape="rect" coords="183,443,212,477" href="11" alt="" title="">
<area shape="circle" coords="107,271,42" href="32" alt="" title="">
<area shape="poly" coords="361,230,367,241,424,239,410,202,360,229" href="2" alt="" title="">
<area shape="poly" coords="30,176,21,209,18,248,20,282,64,280,62,253,72,228,83,199,31,172" href="2" alt="" title="">
</map>
嗨jamietre,你能联系我吗?阿隆(at)simpletick(dot)com 谢谢! – aron 2011-06-02 16:13:01