Quote:
Originally Posted by marcobranco1975
Boas
Eu tenho este código
Code:
<html xmlns="http://www.w3.org/1999/xhtml" >
<head><title>
Untitled Page
</title>
<script type="text/javascript">
function poorman_toggle(id)
{
var tr = document.getElementById(id);
if (tr==null) { return; }
var bExpand = tr.style.display == '';
tr.style.display = (bExpand ? 'none' : '');
}
</script>
</head>
<body>
<div>
<table border="1">
<tr id="trGrpHeader1">
<td width="100"><span onclick="java script:poorman_toggle('Row1');">Row 1</span></td>
<td width="100"><span onclick="java script:poorman_toggle('Row2');">Row 2</span></td>
<td width="100"><span onclick="java script:poorman_toggle('Row3');">Row 3</span></td>
</tr>
<tr id="Row1">
<td width="100"> Row1 - Data</td>
<td width="100" class="number">1</td>
<td width="100" class="number">4</td>
</tr>
<tr id="Row2">
<td> Row 2 - Data</td>
<td class="number">2</td>
<td class="number">5</td>
</tr>
<tr id="Row3">
<td> Row 3 - data</td>
<td class="number">3</td>
<td class="number">6</td>
</tr>
</table>
</div>
</body>
</html>
Question:
How could i hide data rows on the startup of the page (when i load the page), and show only the headder?
Marco
|
Hi,
you can use timer on onload() event you can set the timer after loading the page timer starts and then when timer finish its execution load ur table this what can do if u want ur table to automatically load after page load if u want to load table manually u can write function for on click event to load table
|