Extracting data from an HTML table
Extracting data from an HTML table
DataSource supports using a table in markup as its source of truth.
This example illustrates how to create a "pass-thru" DataSource instance to leverage the DOM walking and parsing routines inside in order to extract the table's data into a JavaScript array structure.
Total Amount Due: (click the Extract button)
Table in markup with data in it
Due Date
Account Number
Quantity
Amount Due
1/23/1999
29e8548592d8c82
12
$150.00
5/19/1999
83849
8
$60.00
8/9/1999
11348
1
-$34.99
1/23/2000
29e8548592d8c82
10
-$1.00
4/28/2000
37892857482836437378273
123
$33.32
1/23/2001
83849
5
-$15.00
9/30/2001
224747
14
$56.78
yui_2.7.0b.zip( 4,431 k)