Post by hey on Dec 29, 2005 12:31:24 GMT -8
This code combines the Topics/Posts column and the Replies/Views column with the last post column, and puts the thread starter under the topic name.
Preview 1
Preview 2
Global Footer:
<script type="text/javascript">
/*Fusion Last Post Mod B by hey
No reposting, keep header intact */
var td = document.getElementsByTagName('td');
for (i = 0; i < td.length; i++){
if(td.width == '66%' && td.className == 'windowbg2'){
var topicCount = td[i+1].getElementsByTagName('font')[0].innerHTML;
var postCount = td[i+2].getElementsByTagName('font')[0].innerHTML;
td[i+3].innerHTML = '<font size="1">Topics: ' + topicCount + ' Posts: ' + postCount + '</font><br />' + td[i+3].innerHTML;
td[i+1].style.display='none';
td[i+2].style.display='none';
}
if(td.className == 'titlebg' && td.innerHTML.match(/<b>Topics<\/b>/i)){
td.style.display='none';
td[i+1].style.display='none';
td[i+2].innerHTML = 'Board Statistics';
}
if(td.width.match(/(43%|48%)/i) && td.className == 'windowbg'){
var threadStarter = td[i+1].getElementsByTagName('font')[0].innerHTML;
var replyCount = td[i+2].getElementsByTagName('font')[0].innerHTML;
var viewCount = td[i+3].getElementsByTagName('font')[0].innerHTML;
td.innerHTML += '<br /><font size="1">Started by: ' + threadStarter + '</font>';
td[i+4].innerHTML = '<font size="1">Replies: ' + replyCount + ' Views: ' + viewCount + '</font><br />' + td[i+4].innerHTML;
td[i+4].width='24%';
td[i+1].style.display='none';
td[i+2].style.display='none';
td[i+3].style.display='none';
}
if(td.className == 'catbg' && td.innerHTML.match(/<b>Replies<\/b>/i)){
td[i-1].style.display='none';
td.style.display='none';
td[i+1].style.display='none';
td[i+2].width='24%';
td[i+2].innerHTML = 'Thread Statistics';
}
}
</script>
Preview 1
Preview 2
Global Footer:
<script type="text/javascript">
/*Fusion Last Post Mod B by hey
No reposting, keep header intact */
var td = document.getElementsByTagName('td');
for (i = 0; i < td.length; i++){
if(td.width == '66%' && td.className == 'windowbg2'){
var topicCount = td[i+1].getElementsByTagName('font')[0].innerHTML;
var postCount = td[i+2].getElementsByTagName('font')[0].innerHTML;
td[i+3].innerHTML = '<font size="1">Topics: ' + topicCount + ' Posts: ' + postCount + '</font><br />' + td[i+3].innerHTML;
td[i+1].style.display='none';
td[i+2].style.display='none';
}
if(td.className == 'titlebg' && td.innerHTML.match(/<b>Topics<\/b>/i)){
td.style.display='none';
td[i+1].style.display='none';
td[i+2].innerHTML = 'Board Statistics';
}
if(td.width.match(/(43%|48%)/i) && td.className == 'windowbg'){
var threadStarter = td[i+1].getElementsByTagName('font')[0].innerHTML;
var replyCount = td[i+2].getElementsByTagName('font')[0].innerHTML;
var viewCount = td[i+3].getElementsByTagName('font')[0].innerHTML;
td.innerHTML += '<br /><font size="1">Started by: ' + threadStarter + '</font>';
td[i+4].innerHTML = '<font size="1">Replies: ' + replyCount + ' Views: ' + viewCount + '</font><br />' + td[i+4].innerHTML;
td[i+4].width='24%';
td[i+1].style.display='none';
td[i+2].style.display='none';
td[i+3].style.display='none';
}
if(td.className == 'catbg' && td.innerHTML.match(/<b>Replies<\/b>/i)){
td[i-1].style.display='none';
td.style.display='none';
td[i+1].style.display='none';
td[i+2].width='24%';
td[i+2].innerHTML = 'Thread Statistics';
}
}
</script>