Post by coolcoolcool on Mar 23, 2007 18:25:04 GMT -8
Description: It gives you the "option" to do both or either of the following:
Compatibility: Tested in IE 6.0 and Firefox 2.0
Location: "Main" Footer (I cannot insure compatibility in global footers)
<script type="text/javascript">
var modify_front_page = {
move_last_post: "yes", // put yes if you would like to move the last post column to the left of posts/topics
remove_on_off: "yes", // put yes if you would like to remove the on/off icons
exec: function(){
this.do_work();
},
do_work: function(){
var cells = document.getElementsByTagName("td");
var newCell;
for(var a = cells.length - 13; a > -1; a--){
if((cells.item(a).className.match(/windowbg2/i) && cells.item(a).width=="24%" || cells.item(a).className.match(/titlebg/i) && cells.item(a).width=="24%") && this.move_last_post.match(/yes/i)){
newCell = cells.item(a).parentNode.insertCell(cells.item(a).cellIndex-2);
newCell.innerHTML = cells.item(a + 1).innerHTML;
newCell.className = cells.item(a + 1).className;
newCell.vAlign = cells.item(a + 1).vAlign;
cells.item(a + 1).parentNode.removeChild(cells.item(a + 1));
} else if(this.remove_on_off.match(/yes/i) && cells.item(a).firstChild && cells.item(a).firstChild.alt !== undefined && cells.item(a).firstChild.alt.match(/\[(\s|\*)\]/i)){
cells.item(a).parentNode.removeChild(cells.item(a));
} else if(this.remove_on_off.match(/yes/i) && ((cells.item(a).colSpan == "2" && !cells.item(a).innerHTML.match(/(in|st|us|se|re)/i)) || cells.item(a).colSpan == "5")){
cells.item(a).colSpan--;
}
}
}
};
modify_front_page.exec();
</script>
- Remove the on/off icons from the main page.
- Move the Last Post column to before the posts and topics.
Compatibility: Tested in IE 6.0 and Firefox 2.0
Location: "Main" Footer (I cannot insure compatibility in global footers)
<script type="text/javascript">
var modify_front_page = {
move_last_post: "yes", // put yes if you would like to move the last post column to the left of posts/topics
remove_on_off: "yes", // put yes if you would like to remove the on/off icons
exec: function(){
this.do_work();
},
do_work: function(){
var cells = document.getElementsByTagName("td");
var newCell;
for(var a = cells.length - 13; a > -1; a--){
if((cells.item(a).className.match(/windowbg2/i) && cells.item(a).width=="24%" || cells.item(a).className.match(/titlebg/i) && cells.item(a).width=="24%") && this.move_last_post.match(/yes/i)){
newCell = cells.item(a).parentNode.insertCell(cells.item(a).cellIndex-2);
newCell.innerHTML = cells.item(a + 1).innerHTML;
newCell.className = cells.item(a + 1).className;
newCell.vAlign = cells.item(a + 1).vAlign;
cells.item(a + 1).parentNode.removeChild(cells.item(a + 1));
} else if(this.remove_on_off.match(/yes/i) && cells.item(a).firstChild && cells.item(a).firstChild.alt !== undefined && cells.item(a).firstChild.alt.match(/\[(\s|\*)\]/i)){
cells.item(a).parentNode.removeChild(cells.item(a));
} else if(this.remove_on_off.match(/yes/i) && ((cells.item(a).colSpan == "2" && !cells.item(a).innerHTML.match(/(in|st|us|se|re)/i)) || cells.item(a).colSpan == "5")){
cells.item(a).colSpan--;
}
}
}
};
modify_front_page.exec();
</script>