Bug Tracker

Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#7153 closed bug (worksforme)

attribute selector with namespace does not find valid selectors when used as context or with find().

Reported by: daniel hai Owned by:
Priority: undecided Milestone: 1.4.3
Component: selector Version: 1.4.2
Keywords: Cc:
Blocked by: Blocking:

Description

original question: http://stackoverflow.com/questions/3910332/jquery-finding-filtering-on-attributes-within-context/3910392#3910392

This works:

returns div, ul, article console.log($('[ui
:component]'));

These should work, but do not:

these all return nada console.log($('[ui
:component]', $('body'))); console.log($('body').find('[ui
:component]'));

FILE BELOW:

<html> <head>

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>

</head> <body>

<div ui:component="component1"></div> <ul ui:component="component2"></ul> <article ui:component="component3"></article>

</body> <script type="text/javascript"> $(document).ready(function() {

returns div, ul, article console.log($('[ui
:component]'));

these all return nada console.log($('[ui
:component]', $('body'))); console.log($('body').find('[ui
:component]')); console.log($('body').filter('[ui
:component]')); console.log($('body').find('*').filter('[ui
:component]'));

}); </script> </html>

Change History (2)

comment:1 Changed 9 years ago by john

Resolution: worksforme
Status: newclosed

This was fixed in jQuery 1.4.3.

comment:2 Changed 9 years ago by john

Component: unfiledselector
Note: See TracTickets for help on using tickets.