Setting table height dynamically after page has been loaded

Setting table height dynamically after page has been loaded

OK, I am very new to jQuery so bare with me here.

I am trying to get the document body height and set it as the height of a table, after the page has been loaded. Below is an example of what I am trying to do.

<table id="heightTable" cellpadding="5" cellspacing="0" height="" style="visibility:hidden">
<tr>
<td>&nbsp;</td>
</tr>
</table>');


$(document).ready(function() {
   $(#heightTable).height($(document.body).height());
                     }


I am not sure where to place the jQuery code, before or after the table tag...and I am not even sure if any of my jQuery code is correct. Once again, i need to set the table height AFTER the document has been loaded and then dynamically change the height of the table.

Any help would be appreciated!