Post by Hechizero on Jul 31, 2004 8:38:32 GMT
Script Name: Separate Posts with Top and Bottom Image
Description: Separate one post from the other and add an image at the top and bottom of that post.
Hack Type: Thread-Enable
Version: 1.0
Previews: -----
All Boards Footer:
How to Customize it?:
1. Post Top Image
Search fot this part at the top of the script:
var PostTopImg='URL TO TOP IMAGE';
And edit the red part with the url of the image that you want to appear at the top of a post.
2. Post Bottom Image
Search fot this part at the top of the script:
var PostBottomImg='URL TO BOTTOM IMAGE';
And edit the red part with the url of the image that you want to appear at the bottom of a post.
3. Gap Size
Search fot this part at the top of the script:
var GapSize=0;
And edit the red part with the number of pixels that you want the gap size to be.
Location: All Boards Footers.
Description: Separate one post from the other and add an image at the top and bottom of that post.
Hack Type: Thread-Enable
Version: 1.0
Previews: -----
All Boards Footer:
<script language="javascript" type="text/javascript">
/* Created by Hechizero - http://www.hechizero.com
Separate Posts with Top and Bottom Image v1.0
This code may not redistributed without the express permission from its creators.
This header must stay intact at all times. */
var PostTopImg='URL TO TOP IMAGE';
var PostBottomImg='URL TO BOTTOM IMAGE';
var GapSize=0;
if (location.href.match(/action=display/i)) {
var tables=document.getElementsByTagName('table');
for (var h=0,e=c=false;h<tables.length;h++) {
var t=tables[h];
if (t.cellPadding=='0' && t.cellSpacing=='0' && t.width=='100%' && t.rows[0].cells[0].firstChild.tagName=='TABLE') {
if (t.className=='bordercolor' && t.align=='center' && t.rows[0].cells[0].firstChild.rows[0].cells[0].className.match(/windowbg/i)) {
var newImg=document.createElement('img');
newImg.src=PostTopImg;
t.parentNode.insertBefore(newImg,t);
var newDiv=document.createElement('div');
newDiv.style.height=GapSize+'px';
t.parentNode.insertBefore(newDiv,newImg);
if (e) {
newImg=document.createElement('img');
newImg.src=PostBottomImg;
t.parentNode.insertBefore(newImg,newDiv);
}
e=true;
} else if (t.rows[0].cells[0].firstChild.rows[0].cells[0].className=='titlebg' && t.rows[0].cells[0].firstChild.rows[0].cells[0].width=='100%') {
if (c) {
var newDiv=document.createElement('div');
newDiv.style.height=GapSize+'px';
t.parentNode.insertBefore(newDiv,t);
var newImg=document.createElement('img');
newImg.src=PostBottomImg;
t.parentNode.insertBefore(newImg,newDiv);
}
c=true;
}
}
}
}
</script>
How to Customize it?:
1. Post Top Image
Search fot this part at the top of the script:
var PostTopImg='URL TO TOP IMAGE';
And edit the red part with the url of the image that you want to appear at the top of a post.
2. Post Bottom Image
Search fot this part at the top of the script:
var PostBottomImg='URL TO BOTTOM IMAGE';
And edit the red part with the url of the image that you want to appear at the bottom of a post.
3. Gap Size
Search fot this part at the top of the script:
var GapSize=0;
And edit the red part with the number of pixels that you want the gap size to be.
Location: All Boards Footers.