|
Re: [jQuery] Form plugin revisited ;-): msg#01204lang.javascript.jquery
> How does jQuery(':input', this) differ from > jQuery('input,textarea,select,button', this) ? Great question, Aaron, The ":input" selector will grab all elements and then filter them using a regex match of the nodeName against "input|select|textarea|button". On the other hand, the "input,textarea,select,button" selector will grab only those elements (using getElementsByTagName I believe) and it will grab them *in that order*. So the first expression guarantees us semantic ordering of the selected elements but is slower due to the regex matching. Mike
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: [jQuery] jQuery Website Gallery, Ⓙⓐⓚⓔ |
|---|---|
| Next by Date: | Re: [jQuery] Possible changes to hide/show, Brandon Aaron |
| Previous by Thread: | Re: [jQuery] Form plugin revisited ;-), Aaron Heimlich |
| Next by Thread: | Re: [jQuery] Form plugin revisited ;-), Aaron Heimlich |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |