sosuke
03-23-2006, 05:44 AM
I can't use getElementById on <tbody> in IE for some reason, anyone know why? I have also tried:
document.getElementsByTagName("tbody").item(0);
does anyone know a slick way to add content to a existing table? i am passing <tr> blocks back from php to javascript using sajax.
it works perfect in firefox
the reason why i don't pass the entire tab back each time is because each of the columns is sortable
here is my table:
<div id="datExample">
<table class="dynatab" id="workshopQueryTable" border="0">
<tr>
<th> </th>
<th> </th>
<th> </th>
<th colspan="2" align="center"><font style="font-size:.8em !important; text-align:center">Times are in 24 hour format.</font></th>
<th colspan="6"> </th>
</tr>
<tr class="yellow" id="workshopQueryHeader">
<th>Delete</th>
<th>RO</th>
<th class="sortable">Date</th>
<th class="sortable">Start Time</th>
<th class="sortable">End Time</th>
<th class="sortable">Venue</th>
<th class="sortable">Address</th>
<th class="sortable">City</th>
<th class="sortable">State</th>
<th class="sortable">Zip</th>
<th class="sortable">ID</th>
</tr>
<tbody id="workshopQueryContent">
</tbody>
</table>
</div>
here is the javascript that works in mozilla but not IE:
function printTable(result) {
document.getElementById("workshopQueryContent").innerHTML = result;
setMessage("Complete!");
}
document.getElementsByTagName("tbody").item(0);
does anyone know a slick way to add content to a existing table? i am passing <tr> blocks back from php to javascript using sajax.
it works perfect in firefox
the reason why i don't pass the entire tab back each time is because each of the columns is sortable
here is my table:
<div id="datExample">
<table class="dynatab" id="workshopQueryTable" border="0">
<tr>
<th> </th>
<th> </th>
<th> </th>
<th colspan="2" align="center"><font style="font-size:.8em !important; text-align:center">Times are in 24 hour format.</font></th>
<th colspan="6"> </th>
</tr>
<tr class="yellow" id="workshopQueryHeader">
<th>Delete</th>
<th>RO</th>
<th class="sortable">Date</th>
<th class="sortable">Start Time</th>
<th class="sortable">End Time</th>
<th class="sortable">Venue</th>
<th class="sortable">Address</th>
<th class="sortable">City</th>
<th class="sortable">State</th>
<th class="sortable">Zip</th>
<th class="sortable">ID</th>
</tr>
<tbody id="workshopQueryContent">
</tbody>
</table>
</div>
here is the javascript that works in mozilla but not IE:
function printTable(result) {
document.getElementById("workshopQueryContent").innerHTML = result;
setMessage("Complete!");
}