im looking for a way to grab all innerText values of a list of divs and then split them by types in the code i wrote i took the firs set of divs and turned them into inouts with the innertext as the class name and tthe second set and turned them into the input value.. what im looking to do is now sort them add all values with the same classnames together.. any idea on how to do this? they dont need to be inputs they can be arrays or anything.. catch is i wont know how many divs there are so i cant just say all that = this class name blah blah blah.. heres what i have so far.
any help would be greatly appreciated
[code]
<script>
function rounder(){
j=document.getElementById(‘joker’).getElementsByTagName(‘div’);
for (i=0;i<j.length;i++) {
k = j[i];
if (k.className.match(“active-column-3″)) {
kf=k.innerText;
var aElement=document.createElement(‘input’);
aElement.name=’name’+i;
aElement.id=’id’+i;
aElement.className=’N_’+kf.replace(/-/g,”);
//aElement.setAttribute(“onclick”,”alert(this.className)”);
}
if (k.className.match(“active-column-5″)) {
kf=k.innerText;
aElement.value=kf;
oData.appendChild(aElement);
}
}
v=document.getElementById(‘oData’).getElementsByTagName(‘input’);
jol=”;
for (z=0;z<v.length;z++) {
kk = v[z];
}
}
</script>