Spoiler Box, PLease HELP!

Talk about anything you want, but keep it within the rules, please.
User avatar
Ozzapoo
The Flying Cow!
Posts: 2196
Joined: November 2nd, 2007, 10:34 pm
Location: Melbourne

Spoiler Box, PLease HELP!

Post by Ozzapoo »

Hi, I was just wondering what code was used to make the 'Spoiler Box' BBCode? I've looked on the internet but I can't find a useable answer :( Please help!
Spoiler:
I really want to know!
Visit Ozzapoo.net, my blog and the home of AutoCP and Cheatpack Detector!
AutoCP3 now available for free!
GeorgeMots
Crusader
Posts: 4236
Joined: January 27th, 2007, 4:46 pm
Location: Greece, Veria

Re: Spoiler Box, PLease HELP!

Post by GeorgeMots »

Im not a pro on this and im pretty sure Dekar knows the answer but you can look in the HTML source of the page.

Here is what i found
Spoiler:
<div class="smallfont" style="margin-bottom:2px"><b>Spoiler</b>: <input type="button" value="Show" style="width:45px;font-size:10px;margin:0px;padding:0px;" onClick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = ''; this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }">

</div>
<div class="alt2" style="margin: 0px; padding: 6px; border: 1px inset;">
<div style="display: none;">
I really want to know!
</div>
</div>
</div></div>
http://slowbro.org/
`·.,¸,.·*¯`·.,¸,.·*¯[;::;(。◕‿‿­­​­­­­­◕。)
Image
Image
Image
Spoiler:
(03:36:55) xkiska: im too much of a dumbass to understand this
User avatar
Dekar
Forum Drunk
Posts: 2899
Joined: January 17th, 2007, 4:22 pm
Has thanked: 1 time
Been thanked: 1 time

Re: Spoiler Box, PLease HELP!

Post by Dekar »

Code: Select all

[spoiler={TEXT1}]{TEXT2}[/spoiler]

Code: Select all

<div style="margin:20px; margin-top:5px">
<div class="smallfont" style="margin-bottom:2px"><b>Spoiler</b> for <i>{TEXT1}</i>: <input type="button" value="Show" style="width:45px;font-size:10px;margin:0px;padding:0px;" onClick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';		this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }">
</div>
<div class="alt2" style="margin: 0px; padding: 6px; border: 1px inset;">
<div style="display: none;">
{TEXT2}
</div>
</div>
</div>

Code: Select all

[spoiler]{TEXT}[/spoiler]

Code: Select all

<div style="margin:20px; margin-top:5px">
<div class="smallfont" style="margin-bottom:2px"><b>Spoiler</b>: <input type="button" value="Show" style="width:45px;font-size:10px;margin:0px;padding:0px;" onClick="if (this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display != '') { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = '';		this.innerText = ''; this.value = 'Hide'; } else { this.parentNode.parentNode.getElementsByTagName('div')[1].getElementsByTagName('div')[0].style.display = 'none'; this.innerText = ''; this.value = 'Show'; }">
</div>
<div class="alt2" style="margin: 0px; padding: 6px; border: 1px inset;">
<div style="display: none;">
{TEXT}
</div>
</div>
</div>
Don't pm me with Warcraft questions, this is a forum so just make a post!
In the world of thinking we are all immigrants. -Robert Nozick
User avatar
Ozzapoo
The Flying Cow!
Posts: 2196
Joined: November 2nd, 2007, 10:34 pm
Location: Melbourne

Re: Spoiler Box, PLease HELP!

Post by Ozzapoo »

Thanks! Ur the best! :D
Visit Ozzapoo.net, my blog and the home of AutoCP and Cheatpack Detector!
AutoCP3 now available for free!