With the traversing method, you can match a set of elements then select, for
example, the third one
$('.myclass,#myid').eq(2)

I didn't use the traversing method but i think that is one of possible usage

Pierre

2009/6/10 Maujor <css.mau...@gmail.com>

>
>
> According jQuery documentation  [1][2]
> :eq returns Array <Element> and eq() returns one jQuery object.
> What does means "Array <Element>"? It is a single element?
> By the other hand eq() => "Reduce the set of matched elements to a single
> element."
> So, both returns a single element and it seems to me that there isn't any
> difference between :eq and eq().
> Is one faster than the other?
> Why are there two sintaxes to achieve the same task? Or am I missing
> sometghing?
>
> [1] http://docs.jquery.com/Selectors
> [2] http://docs.jquery.com/Traversing
>
> -----
> MaurĂ­cio Samy Silva
> --
> View this message in context:
> http://www.nabble.com/%3Aeq-versus-eq%28%29-tp23962849s27240p23962849.html
> Sent from the jQuery General Discussion mailing list archive at Nabble.com.
>
>

Reply via email to