#1155 ✓duplicate
Robert Hofer

Event.on does not support blur-event

Reported by Robert Hofer | October 13th, 2010 @ 04:14 PM

<SCRIPT type="text/javascript" src="../deepbase.js/prototype.js"></SCRIPT>
<body>
<input type=text><br>
<input type=text><br>
 <script type="text/javascript">
//$$('input').invoke('observe','blur',function (){alert('blur')})//<--this works       
Event.on(document.body,"blur",'input',function (){alert('blur')})//<--- doesent work, blur not supported; change, click etc. work fine
</script>
</body>

Comments and changes to this ticket

  • Arthur Schreiber

    Arthur Schreiber October 13th, 2010 @ 05:38 PM

    The bug tracker is only for bugs in Prototype, not problems on your part due to wrong usage or missing understanding.

    Please use the mailing list http://groups.google.com/group/Prototypejs/ for your requests.

    Your issue was already discussed in https://prototype.lighthouseapp.com/projects/8886/tickets/666-make-.... Not bubbling blur/focus events is browser-default behaviour and thus your script does not work, as Event.on relies on event bubbling.

  • John-David Dalton

    John-David Dalton October 13th, 2010 @ 08:54 PM

    • Assigned user set to “GitHub Robot”
    • Tag set to feature request

    Consider it a feature request as other projects like jQuery and FuseJS support it. (even prototype-ujs attempts to).
    Prototype's event delegation code, similar to MooTools, is merely a thin layer of sugar for the delegation pattern. It does not address any of the cross-browser issues.

  • Arthur Schreiber

    Arthur Schreiber October 13th, 2010 @ 10:26 PM

    Anyway, there already is a ticket for this open (I linked to it in my previous comment), so this one should be marked as a duplicate.

  • John-David Dalton

    John-David Dalton October 13th, 2010 @ 11:01 PM

    Well this one is more relevant as it points to current API requesting specific enhanced functionality.

    The other is a request to add support for cross-browser focusin/focusout.

    Also it is apparently evil (check out its ticket number, #666),
    That ticket is about 2 minutes away from crab walking down the stairs and spitting up pea soup :0

  • Andrew Dupont

    Andrew Dupont October 14th, 2010 @ 08:09 AM

    • State changed from “new” to “duplicate”
    • Assigned user cleared.
    • Importance changed from “” to “Low”

    Nope, it's a duplicate.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

The Prototype JavaScript library.

Shared Ticket Bins

Pages