Can anyone help out with changing the number of columns in the following code to 4 columns.
Thanks
Thanks
Code:
<SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript"> <!-- function SectionList(ar) { var col = 1; var strIDs = '<table width="100%"><tr><td valign=top width="50%">'; for (var i=1;i<=ar.length;i++) { if (ar[i].sURL !=null) { strIDs += '<a href="' + ar[i].sURL + '"><span class="mymenutop">' + ar[i].sName + '</span></a><br>'; { if (ar[i].pChild) { for (var j=1;j<=ar[i].pChild.length;j++) { if (j <= ar[i].pChild.length) { strIDs += '<a href="' + ar[i].pChild[j].sURL + '"><span class="mymenulevels">' + ar[i].pChild[j].sName + '</span></a><br>'; } } } } if ( col == 1 ) { strIDs += '</td><td valign=top width="50%">'; col++; } else { strIDs += '</td></tr><tr><td valign=top width="50%">'; col = 1; } } } if ( col == 1 ) strIDs += '</td><td>'; return strIDs + '</td></tr></table>'; } //--> </SCRIPT>
Comment