Re: event bubbling IE onpaste
- From: Martin Honnen <mahotrash@xxxxxxxx>
- Date: Mon, 26 Sep 2005 15:45:47 +0200
bernhard schelling wrote:
Wenn ich den onpaste Event sowohl auf der Textarea wie auch auf dem document abfangen will, sollte folgendes Script meiner meinung nach zweimal "1" alerten, da der onpaste event nach oben bubbelt. Passiert aber nicht. Kann mich jemand aufklären warum?
Nicht wirklich, die Doku
<http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/events/onpaste.asp>
sagt "bubbles: yes" und listet unter anderem das document Objekt.
Mein Test hier (IE 6) bestaetigt aber, das paste/onpaste nicht beim document Objekt ankommt. Allerdings bekommen alle Vorfahr-Elemente das Event, also
<body onpaste
oder
<form onpaste
werden aufgerufen, wenn die Textarea darin enthalten ist.
Eventuell halt in document.body.onpaste einhaengen, wenn du Dokument-weit auf onpaste reagieren willst.
--
Martin Honnen http://JavaScript.FAQTs.com/ .
- Follow-Ups:
- Re: event bubbling IE onpaste
- From: bernhard schelling
- Re: event bubbling IE onpaste
- References:
- event bubbling IE onpaste
- From: bernhard schelling
- event bubbling IE onpaste
- Prev by Date: Re: wie lade ich am besten js nach?
- Next by Date: Re: wie lade ich am besten js nach?
- Previous by thread: event bubbling IE onpaste
- Next by thread: Re: event bubbling IE onpaste
- Index(es):