I use JQUERY but have the need to use a piece of JavaScript in the specific case. The problem I’m having is being able to reference the specific object I want in Javascript.
In JQUERY I would state $('div#uniqueID div.genericClass') – FYI there are many of the uniqueID divs and each has the genericClass below.
This the Javascript I’m trying to use (there is more code but its not specifically important in this case:
function insertEmoticonAtTextareaCursor(uniqueID,text) {
var txtarea = document.getElementById(uniqueID);
}
I’m calling this code from JQUERY using:
insertEmoticonAtTextareaCursor(uniqueID,emoticonSymbol)
The object I need to access is
$('div#uniqueID div.genericClass')
How can I get the ‘txtarea’ variable to be linked to $('div#uniqueID div.genericClass')?
thankyou
Try this: