Hi. I'm trying to figure out how to count number of <col />-tags inside the document. The reason I need to count them, is that the pages will be generated, and there is no way of knowing how many columns there will be, or what their id-tag will be.
Code:
var testObj = document.getElementById("colGroup").childNodes;
returned a very high number, so I guess that's no good.
I will also need to find out how to access the id-tag
sample code:
Code:
<colgroup id="colGroup">
<col span="2" id="date" />
<col id="win32" />
<col id="win32_md_debug" />
<col id="win32_md_release" />
<col id="win32_mt_debug" />
<col id="win32_mt_release" />
<col id="ubuntu32" />
<col id="ubuntu32_release" />
<col id="solaris32" />
<col id="solaris32_release" />
<col id="osx32" />
<col id="osx32_release" />
<col id="centos64" />
<col id="centos64_release" />
<col id="gentoo64" />
<col id="gentoo64_release" />
</colgroup>