Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
62
rated 0 times [  63] [ 1]  / answers: 1 / hits: 72813  / 11 Years ago, tue, april 9, 2013, 12:00:00

How to get inner text of a DIV controller using java script?


More From » html

 Answers
76

Suppose you have a div declared as:



<div id=someDiv>
some content goes here
</div>


You can get its value by:



// javascript
document.getElementById(someDiv).innerHTML
// jquery
$(#someDiv).html()

[#79021] Monday, April 8, 2013, 11 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
andreguym

Total Points: 125
Total Questions: 112
Total Answers: 103

Location: Wallis and Futuna
Member since Tue, Mar 30, 2021
3 Years ago
;