> Your example use xpath ?

No, it uses a CSS 3 attribute selector.

http://www.w3.org/TR/css3-selectors/#attribute-selectors


> How jquery know what id forum-list- has ?

It doesn't. The selector matches a substring of the id, e.g. it will
match "forum-list-0", "forum-list-1", ... but it would also match
"forum-list-foo".


> Your method is faster than Karl Rudd example?

Internally jQuery has to loop over all items in the result, so there
won't be much of a difference. But matching elements by id like in
Karl's example may be a bit faster than using a type and attribute
selector.


--Klaus

Reply via email to