: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Rick, as far as I can tell there is something wrong with two of the code
examples you provided.
var mySet = '$(mySet)'; ...this sets the mySet variable to a string
that *looks* like a jQuery selector, but your
mySet is an object or variable, $(mySet) will try to get an element
using the contents of mySet as the selector.
On Mar 5, 10:04 am, ggerri gerald.ressm...@ewz.ch wrote:
Hi there
thats an easy one for you ;-)
if i do:
var mySet = $('trtd:nth-child(2n)');
how do I use mySet? What's the
Thanks Ryan :handshake:
so mySet.find(':text').each(...) would be right and
$(mySet).find(':text').each(...) not? :confused:
In examples I often see (within an each function): $(this).something but
also this.something
Still dont get the difference of use :,(
G
-en@googlegroups.com [mailto:jquery...@googlegroups.com] On Behalf
Of ggerri
Sent: Thursday, March 05, 2009 7:31 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Thanks Ryan :handshake:
so mySet.find(':text
[mailto:jquery...@googlegroups.com] On
Behalf Of ggerri
Sent: Thursday, March 05, 2009 7:31 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Thanks Ryan :handshake:
so mySet.find(':text').each(...) would
...@googlegroups.com] On
Behalf Of ricardobeat
Sent: Thursday, March 05, 2009 11:00 AM
To: jQuery (English)
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
It's mostly done to improve performance. If you save the jQuery object in a
var you only need
)
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
It's mostly done to improve performance. If you save the jQuery object in a
var you only need to find the element once (depending on the selector it's
an expensive operation), and then operate
...@googlegroups.com] On
Behalf Of ggerri
Sent: Thursday, March 05, 2009 7:31 AM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Thanks Ryan :handshake:
so mySet.find(':text').each(...) would be right and
$(mySet
:00 AM
To: jQuery (English)
Subject: [jQuery] Re: Simple one: difference between
varXy.find(':text') and
$(varXy).find(':text')
It's mostly done to improve performance. If you save the jQuery object
in a var you only need to find the element once (depending on the
selector it's an expensive
: Thursday, March 05, 2009 11:58 AM
To: jQuery (English)
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Rick, as far as I can tell there is something wrong with two of the code
examples you provided.
var mySet = '$(mySet)'; ...this sets
, March 05, 2009 11:58 AM
To: jQuery (English)
Subject: [jQuery] Re: Simple one: difference between varXy.find(':text') and
$(varXy).find(':text')
Rick, as far as I can tell there is something wrong with two of the code
examples you provided.
var mySet = '$(mySet)'; ...this sets the mySet
11 matches
Mail list logo