I know this has to be be doable, does anyone know how and if you can do it?
or you can do it this way:
var myVar = 'sup fresh our turn baby!';
var myTextArea = document.getElementById('myArea');
myTextArea.innerHTML += myVar;
Something like this should work:
var textArea = document.getElementById("mytextarea"); // assuming there is a textarea with id = mytextarea
var textToAppend = document.createTextNode("Hello, World!");
textArea.appendChild(textToAppend);
EDIT: or, as Pointy suggested, the last two lines can be replaced by:
textArea.value += "Hello, World!";
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With