Post by Infinite on Apr 20, 2005 13:57:38 GMT
Script Name: Advanced Rank Legend
Script Creator: Infinite/Reverence
Script Version: 1
Software Use: Proboards Version 3 Software
Compatability: Cross Browser
Preview(s): N/A
Features:
[/li][li] Adds a rank legend in the users online box.
[/li][li] Ability to add a spacer, opening symbol, and closing symbol between each rank.
[/li][li] Ability to add extra information to the rank legend.
[/li][li] Ability to easily add more ranks with colors.
Code:
Main Footer
<script>
// Advanced Rank Legend created by Infinite/Reverence.
// Copyright 05, All Rights Reserved.
// This code may not be redistributed without the consent of the creator.
var rankSpacer=" :: "
var rankOpen=" [ "
var rankClose=" ] "
var legendExtra="Extra Here"
var staffArray=[];
staffArray[0]=["Admin","FFFFFF"];
var legendBox=document.createElement("div")
legendBox.innerHTML=legendExtra+"<hr width=100% size=1 class=hr>"
for(a=0;a<staffArray.length;a++){
legendBox.innerHTML+=""+rankOpen+"<font color='"+staffArray[1]+"'>"+staffArray[0]+"</font>"+rankClose+"<span>"+rankSpacer+"</span>"
}
var TD=document.getElementsByTagName("TD")
for(t=0;t<TD.length;t++){
if(TD[t].innerHTML.match(/Guest,/i) && TD[t].className.match(/windowbg/i)){
TD[t].appendChild(legendBox);
var removeSpacer=TD[t].getElementsByTagName("span").length-1
TD[t].getElementsByTagName("span")[removeSpacer].style.display="none"
}}
</script>
Instructions:
Rank Spacer
Change the red to whatever you want to display between each rank, leave blank if you want nothing to be displayed between each rank name.
Rank Open
Change the orange to whatever you want to be displayed before the rank name, leave blank if you want nothing to be displayed before the rank name.
Rank Close
Change the yellow to whatever you want to be displayed after the rank name, leave blank if you want nothing to be displayed after the rank name.
Legend Extra
You can put anything you want here to also be displayed in the users online box, such as links, news, etc.
Leave blank if you do not want to add anything extra.
Array Number
This is the number of ranks you have, starting at 0.
So the first rank array number would be 0, and then the next would be 1, and you would keep increasing the number by one.
Example:
staffArray[0]=["Admin","FFFFFF"];
staffArray[1]=["Gmod","FF0000"];
staffArray[2]=["mod","0000FF"];
staffArray[3]=["Member","000000"];
staffArray[4]=["Mini Member","C0C0C0"];
See how if you add more ranks you must increase the array number.
Rank Name
Change the blue to the name you want that rank to be.
Rank Color
Change the navy to the hex color code that you want that rank name to be colored.
Script Creator: Infinite/Reverence
Script Version: 1
Software Use: Proboards Version 3 Software
Compatability: Cross Browser
Preview(s): N/A
Features:
[/li][li] Adds a rank legend in the users online box.
[/li][li] Ability to add a spacer, opening symbol, and closing symbol between each rank.
[/li][li] Ability to add extra information to the rank legend.
[/li][li] Ability to easily add more ranks with colors.
Code:
Main Footer
<script>
// Advanced Rank Legend created by Infinite/Reverence.
// Copyright 05, All Rights Reserved.
// This code may not be redistributed without the consent of the creator.
var rankSpacer=" :: "
var rankOpen=" [ "
var rankClose=" ] "
var legendExtra="Extra Here"
var staffArray=[];
staffArray[0]=["Admin","FFFFFF"];
var legendBox=document.createElement("div")
legendBox.innerHTML=legendExtra+"<hr width=100% size=1 class=hr>"
for(a=0;a<staffArray.length;a++){
legendBox.innerHTML+=""+rankOpen+"<font color='"+staffArray[1]+"'>"+staffArray[0]+"</font>"+rankClose+"<span>"+rankSpacer+"</span>"
}
var TD=document.getElementsByTagName("TD")
for(t=0;t<TD.length;t++){
if(TD[t].innerHTML.match(/Guest
TD[t].appendChild(legendBox);
var removeSpacer=TD[t].getElementsByTagName("span").length-1
TD[t].getElementsByTagName("span")[removeSpacer].style.display="none"
}}
</script>
Instructions:
Rank Spacer
Change the red to whatever you want to display between each rank, leave blank if you want nothing to be displayed between each rank name.
Rank Open
Change the orange to whatever you want to be displayed before the rank name, leave blank if you want nothing to be displayed before the rank name.
Rank Close
Change the yellow to whatever you want to be displayed after the rank name, leave blank if you want nothing to be displayed after the rank name.
Legend Extra
You can put anything you want here to also be displayed in the users online box, such as links, news, etc.
Leave blank if you do not want to add anything extra.
Array Number
This is the number of ranks you have, starting at 0.
So the first rank array number would be 0, and then the next would be 1, and you would keep increasing the number by one.
Example:
staffArray[0]=["Admin","FFFFFF"];
staffArray[1]=["Gmod","FF0000"];
staffArray[2]=["mod","0000FF"];
staffArray[3]=["Member","000000"];
staffArray[4]=["Mini Member","C0C0C0"];
See how if you add more ranks you must increase the array number.
Rank Name
Change the blue to the name you want that rank to be.
Rank Color
Change the navy to the hex color code that you want that rank name to be colored.