I have table with numbers tht needs to be summarize.
Example:
<td class="mcost_el.entry[0]">93,08</td>
<td class="mcost_el.entry[1]">544,33</td>
How get all values of td elements with class mcost_el.entry[] and summarize it?
For inputs i’m use $('#d1').attr("value");. Is suitable for this task? (by adding value=”” for td)
You can use
.text()rather than what you have suggested.Update your HTML to
Add in javascript for
Example http://jsfiddle.net/tqH4y/
Also, rather than using
.attr("value")in the future, you can just use.val()