Grab the RSS feed

How to get the textarea ID using javascript

Most of the programmers using the comment
element = document.getElementById(id); to get the value or something from the HTML pages.Some times the ID may be changed because of some reasons.At that time we need to get the ID of the HTML element using Javascript and make our coding successfull.
Here I list the coding to get textarea id .

var divEls = document.getElementsByTagName("textarea");
var i = 0;

You can also using this type to get the Id of div.For that simply put the div instead of textarea.

Leave the comments to improve us...


    Real Time Web Analytics