Thursday, May 28, 2009

[jQuery] select parent node in context

within a function for an onchange-handler ($(...).change(function(e)
{...) i tried something like:

$(":parent input[name^=subsequentProperty]", this);

this does not work, but:

$("input[name^=subsequentProperty]", this.parentNode);

does work.

what am i doing wrong? why doesnt the first example work?

No comments: