I have a table that's being generated with PHP
<table id="mytable" class="tablesorter tablesorter-jui ui-widget ui-widget-content ui-corner-all hasStickyHeaders">
<thead style="">//code for headers </thead>
<tbody>
<?php
foreach ($active_participants as $participant)
{
//code for rows..
}
?>
</tbody>
</table>
I am applying the jquery tablesorter plugin to it, however it does not sort(no jquery errors). I need it to display on page load, because it's the first thing the user will see, however can I have it wait for the page to finish loading before applying
$("#myTable").tablesorter({ sortList: [[0,0], [1,0]] });
what is the proper way to do this?