element.match is a boolean operator that tells you if a given element
matches a css selector.
so if you're observing document.click (delegation) and you want to know if
the element was clicked was a particular one...

(this is not an actual example)
if(e.element().match('div.fieldset div.subfield input'))
//input inside subfield inside fieldset was clicked

On Thu, Jul 3, 2008 at 2:35 PM, John-David Dalton <

> @Gareth Evans
>  * will automagically stopObserving on Element#update.
>    Element#remove doesn't automate this because you could keep a
> reference to the element.
>    In 1.6.1 it might be a non issue because the Event system may
> avoid the memoryleak issue alltogeather
>    and not have to worry about stopObserving().
>  * Is element.match just a renaming of element.select?
>  * Event delegation FTW :) (jQuery will soon have it too)
> @Ken Snyder
>  * has fixed IE and WebKits escapeHTML/unescapeHTML to be as
> fully featured as Firefoxes and others.
>  * has replaced the document.write for IE dom loaded
> detection with doScroll
>  * I dig Object.isEmpty, I don't like the "hasProperties" name
> because it may have methods or something.
>  * I believe Juriy has mentioned having optional conditionals for
> Element methods I could see that being
>    similar to an optional selector :)
>  - JDD
> >

You received this message because you are subscribed to the Google Groups 
"Prototype: Core" group.
To post to this group, send email to prototype-core@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 

Reply via email to