[whatwg] onchange attribute on output elements?

Ian Hickson ian at hixie.ch
Wed Jun 23 02:49:56 PDT 2004


On Tue, 15 Jun 2004, Johnny Stenback wrote:
>>
>> Any ideas for getting around this cleanly? (i.e. without saying
>> "output"'s "change" event is an exception.)
>
> Nothing comes to mind right now.

Ok I've added the text above then. formchange is not the default action of
change _if_ the target of change was an output element.


> But this is a problem that should be solved in the spec regardless of
> how event handlers are registerd on output controls. You'll have the
> exact same problem if you're using mutation events on the output
> element.

No, the problem is specific to the "change" event, because the default
action of the "change" event is to fire the "onformchange" event on every
control, which is the event that would typically be used to change the
output control, thus firing the "change" event on the output control.

The mutation events don't have that default action so they don't cause any
cascade effect (unless they themselves change the output control, but
that's another problem altogether, and one that applies to all mutation
event handlers).

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list