jQuery selector takes a second argument that sets context.
I was trying to concatenate a select to the almighty
this
in jQuery, but it just wasn't working.
I tried
$(this + 'input')
Didn't work, so I thought, maybe I need a space between this and input like so:
$(this + ' input')
No go..
Then I ran across this page.
http://stackoverflow.com/questions/306583/jquery-this-selector-and-children
Of course StackOverFlow has the answer.
The working result
$('input', this)Perfect!!!
Comments
Post new comment