Post by Nightwalker on Jul 9, 2010 15:51:17 GMT -6
This code was written by Nightwalker and iPokemon. The idea was made by Nightwalker and some of the coding. The rest of the coding was done by iPokemon Thanks.
Thank you to Wormopolis for letting us use his floating table code. Also thanks to Jordan for the Collapse with Cookie code.
CB:Yes
Description: An easily editable floating side table.
Features:
Welcome table with custom welcome message
Staff table
Editable affiliate table
Side box can be hidden
Editing:
var d="My Welcome Message"; // Edit welcome message here
This is your welcome message you can put whatever you want here.
// Staff
// Example--x[#]=["Staff Display Name","Image/Avatar","Username"];
x[0]=["Staff Display Name","Image/Avatar","Username"];
x[1]=["Staff Display Name","Image/Avatar","Username"];
This is your staff section. The first part is the staff's DISPLAY name. Next you place the url of the staff member's avatar. Last put in the staff member's USERNAME.
To add an extra line copy this but change the red to the next number in the list.
x[3]=["Staff Display Name","Image/Avatar","Username"];
The affiliate section is almost the same
// Affiliates
// Example--a[#]=["Site Name","Site URL","Mini-Banner"];
a[0]=["Site Name","Site URL","Mini-Banner"];
a[1]=["Site Name","Site URL","Mini-Banner"];
First put the site name. Second the site url. Third the url of the site's mini banner.
Lastly you need to edit the width you want the forum to be. You can leave this part out of the code but i recomend using it. Edit this and place it in your global footer.
<script type="text/javascript"><!--
var tablew = document.getElementsByTagName('TABLE');
for(t=0;t<tablew.length;t++) {
if(tablew[t].width=="92%"){
tablew[t].width='1000';
}
}
//--></script>
Global/Main Footer:
Thank you to Wormopolis for letting us use his floating table code. Also thanks to Jordan for the Collapse with Cookie code.
CB:Yes
Description: An easily editable floating side table.
Features:
Welcome table with custom welcome message
Staff table
Editable affiliate table
Side box can be hidden
Editing:
var d="My Welcome Message"; // Edit welcome message here
This is your welcome message you can put whatever you want here.
// Staff
// Example--x[#]=["Staff Display Name","Image/Avatar","Username"];
x[0]=["Staff Display Name","Image/Avatar","Username"];
x[1]=["Staff Display Name","Image/Avatar","Username"];
This is your staff section. The first part is the staff's DISPLAY name. Next you place the url of the staff member's avatar. Last put in the staff member's USERNAME.
To add an extra line copy this but change the red to the next number in the list.
x[3]=["Staff Display Name","Image/Avatar","Username"];
The affiliate section is almost the same
// Affiliates
// Example--a[#]=["Site Name","Site URL","Mini-Banner"];
a[0]=["Site Name","Site URL","Mini-Banner"];
a[1]=["Site Name","Site URL","Mini-Banner"];
First put the site name. Second the site url. Third the url of the site's mini banner.
Lastly you need to edit the width you want the forum to be. You can leave this part out of the code but i recomend using it. Edit this and place it in your global footer.
<script type="text/javascript"><!--
var tablew = document.getElementsByTagName('TABLE');
for(t=0;t<tablew.length;t++) {
if(tablew[t].width=="92%"){
tablew[t].width='1000';
}
}
//--></script>
Global/Main Footer:
<!-- ==============
* Floating Side Bar
* Do not Repost or Edit
* [url]joemaggio.proboards.com[url]
* ©2010 Nightwalker & !ErInUkI_bOx!
=============== -->
<style type="text/css">
#floatBox {top: expression( ( ignoreMe = document.body.scrollTop +20 ) + 'px' ); z-index: 50;}
</style>
<table id="floatBox" cellspacing="1" cellpadding="4" align="left" valign="top" width="200px" class="bordercolor"><tr><td width="100%" class="titlebg" align="center"><a href="javascript: toggle('fBoxBody');">Hide Floating Box</a></td></tr><tbody id="fBoxBody"><tr><td class="titlebg" align="center" width="100%"><font size=2>Welcome</font></td></tr><tr><td valign="top" class="windowbg" align="center" width="100%"><div id="welcomeMessage"></div></td></tr><tr><td valign="top" class="windowbg" align="center" width="100%"><div id="jumpintable"></div></td></tr><tr><td class="titlebg" align="center" width="100%"><font size=2>Staff</font></td></tr><tr><td align="center" valign="top" class="windowbg"><div style="overflow: auto; height: 200px;"><div id="staffinfo"></div></div></td></tr><tr><td class="titlebg" align="center" width="100%"><font size=2>Affiliates</font></td></tr><tr><td align="center" valign="top" class="windowbg"><marquee><div id="affiliateinfo"></div></marquee></td></tr></tbody></table>
<script type="text/javascript"><!--
/* Floating Welcome Box
by Nightwalker & iPokemon
Thanks to Jordan for the Collapse with Cookie code
Thanks to Wormopolis for the floating table code */
var x = new Array();var a = new Array();
/* ++++ EDIT BELOW HERE ++++ */
var d="My Welcome Message"; // Edit welcome message here
// Staff
// Example--x[#]=["Staff Display,Name","Image/Avatar","Username"];
x[0]=["Staff Display Name","Image/Avatar","Username"];
x[1]=["Staff Display Name","Image/Avatar","Username"];
// Affiliates
// Example--a[#]=["Site Name","Site URL","Mini-Banner"];
a[0]=["Site Name","Site URL","Mini-Banner"];
a[1]=["Site Name","Site URL","Mini-Banner"];
/* ++++ EDIT ABOVE HERE ++++ */
for(r=0;r<a.length;r++){
document.getElementById("affiliateinfo").innerHTML+='<a href="'+a[r][1]+'" target="_blank"><img src="'+a[r][2]+'" border="0" height="31" width="88" title="'+a[r][0]+'"/></a>';
}
for(z=0;z<x.length;z++){
document.getElementById("staffinfo").innerHTML+='<img src="'+x[z][1]+'" border="0" height="100" width="100" title="'+x[z][0]+'" /><br /><a href="http://'+pb_forum+'.proboards.com/?action=viewprofile&user='+x[z][2]+'">'+x[z][0]+'</a><br />';
}
function floatBox() {
nv=document.getElementById('floatBox');
nv.style.position=(document.all ? 'absolute' : 'fixed');
nv.style.top=document.body.scrollTop +20;
document.body.insertBefore(nv, document.body.firstChild);
}
floatBox();
document.getElementById("jumpintable").appendChild(document.getElementById("forumjump"));
document.getElementById("welcomeMessage").innerHTML=d;
var cookie_data = document.cookie.split(";");
for(a = 0; a < cookie_data.length; a++){
if(cookie_data[a].match(new RegExp("id:(.+?)=0($|;)","i"))){
if(document.getElementById(RegExp.$1))
document.getElementById(RegExp.$1).style.display = "none";
}
}
function toggle(_id){
var obj = document.getElementById(_id);
if(obj.style.display == ""){
obj.style.display = "none";
document.cookie = "id:" + _id + "=0;expires=Sat, 20 Jan 3000 12:12:12 UTC; path=/;";
} else {
obj.style.display = "";
document.cookie = "id:" + _id + "=0;expires=Sat, 20 Jan 2000 12:12:12 UTC; path=/;";
}
}
// --></script>