W3C home > Mailing lists > Public > public-html@w3.org > August 2007

Re: Dropping <input usemap="">

From: Michael A. Puls II <shadow2531@gmail.com>
Date: Wed, 15 Aug 2007 18:24:22 -0400
Message-ID: <6b9c91b20708151524j2efb803eq88b8cd76168ff88a@mail.gmail.com>
To: "Lachlan Hunt" <lachlan.hunt@lachy.id.au>
Cc: public-html <public-html@w3.org>

On 8/15/07, Lachlan Hunt <lachlan.hunt@lachy.id.au> wrote:
> Michael A. Puls II wrote:
> > The way Firefox handles <input usemap> is great. At the moment, I
> > can't think of one thing about its implementation that is wrong or
> > unexpected.
> Except that, as implemented, it provides none of the purported
> accessibility benefits, since clicking on an area of the client side map
> doesn't submit the form, it follows the hyperlink.  Submitting the form
> with a specific set of co-ordinates would be the only logical reason for
> wanting a client side image map on an input control designed for form
> submission.  If you want hyperlink image map, use img.

Yeh.  As an example, <
http://shadow2531.com/opera/testcases/imagemaps/002.html > shows how
you can use js to simulate <input usemap> with <img usemap> and still
get the X and Y coordinate form submission on non-mapped parts of the

It basically uses an onclick handler with clientX, clientY, offsetLeft
and offsetTop to figure out the coordinates and sets the hidden x and
y inputs before submitting. The example is Opera, FF and Safari
friendly and could be made IE friendly probably.

So, using JS and <img usemap> might be an alternative to <input
usemap>. And, it might provide better support across browsers (as long
as you have JS on).

Received on Wednesday, 15 August 2007 22:24:26 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:15:25 UTC