javascript - Pull value from table -
hello have following on page , pull value: 36424. value change im trying create function pull when call on function.
<table cellspacing="0" cellpadding="3" rules="cols" border="1" id="osdatacount" style="color:black;background-color:white;border- color:#999999;border-width:1px;border-style:solid;border-collapse:collapse;"> <tr style="color:white;background-color:black;font-weight:bold;"> <th scope="col">count(*)</th> </tr><tr> <td>36424</td> </tr> </table>
cheers
no need jquery:
var table = document.getelementbyid('osdatacount'); alert(table.rows[1].children[0].innerhtml); // -> 36424
Comments
Post a Comment