Doxml practice..
by barkkathulla[ Edit ] 2012-09-22 11:54:01
<html>
<head>
<xml src="INFO.xml" id="g"></xml>
</head>
<table>
<tbody>
<table datasrc="#g" border=10>
<thead>
<tr>
<th>name</th>
<th>age</th>
</tr>
</thead>
<tbody>
<tr>
<td><span datafld="name"></span>
<td><span datafld="age"></span>
</tr>
</tbody>
</table>
</html>
EX 23
DISPLAYING DATAS [WITH TOTAL VALUE].
INFO2.XML
<?xml version="1.0"?>
<st>
<s>
<name>sivasiva</name>
<m1>45</m1>
<m2>56</m2>
</s>
<s>
<name>abi</name>
<m1>23</m1>
<m2>56</m2>
</s>
<s>
<name>baba</name>
<m1>36</m1>
<m2>58</m2>
</s>
</st>
DISP4.HTML
<html>
<xml src="info2.xml" id="g"></xml>
<script language="vbscript">
sub a_onclick()
g.recordset.movenext
if g.recordset.eof then
g.recordset.movefirst
end if
end sub
sub b_onclick()
g.recordset.moveprevious
if g.recordset.bof then
g.recordset.movelast
end if
end sub
sub c_onclick
dim t
t=int(g.recordset.fields("m1"))+int(g.recordset.fields("m2"))
r.value=t
end sub
</script>
</pre>
name:<span datasrc="#g" datafld="name"></span><br>
m1:<span datasrc="#g" datafld="m1"></span><br>
m2:<span datasrc="#g" datafld="m2"></span><br>
<input type=button value="next" name=a><br>
<input type=button value="back" name=b><br>
<input type=button value="total" name=c><br>
<input name=r>
</pre>
</html>