There is a website with a textarea in which I want to populate some default text as soon as the website loads but the problem is the textarea tag doesn't have an ID.
document.getElementsByTagName("textarea").value="default text" ;
<textarea name="details" rows="5" cols="25" style="width: 100%; overflow: auto;"></textarea>
I've tried the below code but it isn't working . Do you have any suggestions on how to achieve this ?
document.getElementsByTagName("textarea").value="default text" ;
TA.