[jQuery] Re: Matching content

2008-04-03 Thread Andiih
Thanks Karl So am I "storing" data wrongly - whats the easiest structure to display things, be semantically correct, and search for name/value pairs ? For me DL's seemed the natural way but perhaps I need to put the name and value into attributes of something, then display them separately ? Kar

[jQuery] Re: Matching content

2008-04-01 Thread Karl Swedberg
Hi Andrew, You could do something like this (though there must be a cleaner way?): $('dt').filter(function() { return $(this).text() == a; }).next('dd').filter(function() { return $(this).text() == b; }) --Karl _ Karl Swedberg www.englishrules.com www.learningjquery.com