Sorry, this is a very simple jQuery syntax question, but I can't find anyone to discuss it anywhere (perhaps because I don't know the correct search terms).
I want to select / cache using a variable, and then get the value of the verified inputs. Now I know that I can do this without caching as:
var questionID = (a string)
$(questionID + " input:radio:checked").val()
But I use the div # 'questionID' object several times, so I want to cache it i.e.
questionID = '
$question = $(questionID);
Now that $ question is a jQuery object, I cannot decide how to select things inside it (without using children ())
For example, the following do not work:
$question.(' input:radio:checked)
$($question 'input:radio:checked')
I guess this is really the basic bit of syntax, but I can't find it anywhere, and I tried many combinations with no luck ......
, , jQuery,