|
Post by CD on May 25, 2005 19:25:57 GMT -8
Place: Board Footers Compatiblity: IE 6.0, FF Editing: First three variables. They tell you what they do and how to edit. Description: This code adds a tag (like UBBC) that can be used so that spoilers are not given away and ruin movie, game, or show plots for others. Preview: None<script> // Spoiler Tag v1 // Code may not be redistrbuted without permission // Copyright CDDude229 of Sin Fallen Studios (http://sfstudio.proboards1.com)
// URL to Spoiler tag Image var spoiler = "http://gbhd.iycatacombs.com/ubbc/strikethrough.gif"; // Text to be displayed for where to click spoiler. var text = "Click to right to show spoiler: "; // Font color var col = "000000";
//No need to edit below here. var aTD = document.getElementsByTagName("TD"); var aFO = document.getElementsByTagName("FONT");
if(location.href.match(/action=(modifypost|post|createpoll)/i)){ for(a=0;a<aTD.length;a++){ if(aTD[a].innerHTML.match(/javascript:add/i) && aTD[a].className=="windowbg2" && aTD[a].innerHTML.match(/quote/i)){ aTD[a].innerHTML+='<a href=javascript:add("[spoiler]","[/spoiler]")><img src="'+spoiler+'" alt="Spoiler" title="Spoiler" border="0"><\/a>'; }}}
if(!location.href.match(/action=(modifypost|post|createpoll)/i)){ for(b=0;b<aTD.length;b++){ if(aTD[b].className.match(/windowbg/i) && aTD[b].width=="80%"){ var wbg = aTD[b].bgColor; aTD[b].innerHTML=aTD[b].innerHTML.replace("[spoiler]",text+" <font color='"+wbg+"' onclick='this.style.color=\""+col+"\"'> <b>Spoiler<\/b>: "); aTD[b].innerHTML=aTD[b].innerHTML.replace("[\/spoiler]","<\/font>"); }}}
</script>
Last Edit: May 26, 2005 13:47:30 GMT -8 by Aaron
|
|
|
Post by KazuyaUK on Jun 5, 2005 14:36:21 GMT -8
Nice code, thanks! ;D
Kaz
|
|
|
Post by CD on Jun 5, 2005 15:26:27 GMT -8
Thanks and your welcome.
|
|