Post by $©Ø®Þ!@Ω™ on Jul 16, 2006 11:30:20 GMT -5
<script type='text/javascript'>
/* Category Splitter Final Release by Scorpian
Version 1 - Image above and below boards
http://roddyinnov.proboards75.com */
/*=== Edit These ===*/
var headImg = 'URL'; // URL of head image
var baseImg = 'URL'; // URL of base image
var bgOfBoard = '#696969'; // Your forum's background color
/*=== Do Not Edit ===*/
var riTable = document.getElementsByTagName('table');
var newHTML = "<center><img src='"+headImg+"'/></center><table width='100%' cellspacing='0' cellpadding='0' border='0'><tr><td><table width='100%' cellspacing='1' cellpadding='4' class='bordercolor' border='0'><tr>";
var newStuff = '</table></td></tr></table>';
if(location.href.match(/action=home$/i) || !location.href.match(/action=/i)){
for(a=0; a<riTable.length; a++){
if(riTable[a].cellPadding == 4 && riTable[a].cellSpacing == 1 && riTable[a-1].className == "bordercolor"&& riTable[a].rows[0].cells[0].firstChild.firstChild && riTable[a].rows[0].cells[0].firstChild.firstChild.innerHTML == "Forum Name"){
for(b=0; b<riTable[a].rows.length; b++){
if(riTable[a].rows[b].cells[0].colSpan == 5 && riTable[a].rows[b].cells[0].className == 'catbg' && riTable[a].rows[b].cells[0].align != 'right'){
newStuff += newHTML + riTable[a].rows[0].innerHTML + '</tr>';
newStuff += '<tr>' + riTable[a].rows[b].innerHTML + '</tr>';
for(c=1; c<riTable[a].rows.length; c++){
if(riTable[a].rows[b+c]){
if(riTable[a].rows[b+c].cells[0].className == 'windowbg'){
newStuff += '<tr>' + riTable[a].rows[b+c].innerHTML + '</tr>';
}else{
newStuff += "</table></td></tr></table><center><img src='"+baseImg+"'/></center><div style='height:25;'></div>";
break;
}
}else{
newStuff += "</table></td></tr></table><center><img src='"+baseImg+"'/></center><div style='height:25;'></div>";
break;
}
}
}
}
var newTab = riTable[a].parentNode;
newTab.parentNode.style.backgroundColor = bgOfBoard;
newTab.innerHTML = newTab.innerHTML.replace(newTab.innerHTML,newStuff);
break;
}
}
}
</script>
Yeah, that's right. I coded a category splitter. This is the first final release of it! After 4 prototypes (2 of which worked), I finally made one that's cross browser and splits the categories for members & guests. Simply put it in your MAIN FOOTERS (preferably near the top), and edit appropriately.
This version will add a head image above each category, followed by the forum name row, the category row, each board, then the base image. Version 2 will have the head image with the category name in it.