|
Custom Spoiler Code
I have a spoiler Feature at my site that allows for a custom button title to be initially seen ( great if you wnat to hint what is hidden inside)l
I don't see anything exactly the same here...although some are simular... & have seen many requests for other spoiler ideas, so.... I thought I might share. Please be kind as this is my first shared hack. It's real easy. Just log into the AdminCP=>Custom BBCodes=>Add New BB Code Then do this: Title: Spoiler Tag BB Code Tag Name: Spoiler tag Replacement: Code:
<div class="spoiler"><script>
function showHide(what){
a=what.getElementsByTagName("div")[0];
if(a.style.display=='none'){
a.style.display='block';
}else{
a.style.display='none';
}}
</script>
<input type="button" onclick="showHide(this.parentNode)" value="Spoiler"><b><small>( Click to show/hide )</small></b><div style="display:none">{param}</div></div>
description: Makes a spoiler BBcode , just as any ordinary bbcode use {option}: Click No ..leave the rest at "No" click "save" button & that is it! The code will then be: [spoiler]Hidden Text Here[/spoiler] Then Put Code:
<style>
.spoiler div{
border:ridge;
border-bottom-color:#999999;
border-top-color:#999999;
border-left-color:#999999;
border-right-color:#999999;
border-bottom-width:thin;
border-top-width:thin;
border-left-width:thin;
border-right-width:thin;
}
</style>
And you can see a different spoiler code being added. Click on Install if Have Installed It , please tell me what should i do if it is not working correctly is in demo what i just did it in my forum is working now , so just added it here Regards to ChopSuey for the demo ![]() ![]() Download No files for download. |
|||||||||
Similar Mods
| BB Code Enhancements Custom Title Spoiler Button | vBulletin 3.8 Add-ons |
| BB Code Enhancements Button spoiler | vBulletin 3.7 Add-ons |