capture textarea value
<textarea id="myTextarea">
Hello World
</textarea>
<script>
var x = document.getElementById("myTextarea").value;
</script>
capture textarea value
<textarea id="myTextarea">
Hello World
</textarea>
<script>
var x = document.getElementById("myTextarea").value;
</script>
js html textarea tag access
/*Let's say you have the following <textarea> tag:
<textarea id="inputMethod"></textarea>
And you want to see it's value. Here's a function you could use:
*/
function getTextArea() {
let value = document.getElementById("inputMethod").value; // Gets value of 'inputMethod' textarea
console.log(value); // Prints value to console
return value;
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us