HTML - Clickthrough Transparent Pixels in PNGs?
While laying out a web开发者_C百科site, I have a png, with a great deal of transparency that I don't want to be mouse enabled. Is there any way to detect transparent pixels, and ignore the mouseOver/mouseDown? If not, does anyone know a good way to fake it?
Thanks in advance.
An image map can be a polygon
http://www.javascriptkit.com/howto/imagemap.shtml
<img src="trees.gif" usemap="#green" border="0">
<map name="green">
<area shape="polygon" coords="19,44,45,11,87,37,82,76,49,98" ...
In addition
With SVG you can fill a polygon with an image and have that polygon be a link. However SVG is not supported by all of the browsers that are in current use. With http://code.google.com/p/svgweb/ you could use SVG to accomplish what you want in a newer fashion.
精彩评论