Demo of a simple spoiler script, used to automatically hide an toggle spoilers. View source to see the usage and look at spoiler.js for the source.
It's very simple to use. Just include the javascript and wrap any spoilers in a div with a class of "spoiler".
For this example, the spoiler class is giving a light border, but you can style it however you want.
Even though this has a "spoiler" class, this is not a spoiler because it's a paragraph, not a div.
You can also add more classes to give spoilers additional style:
You can even nest spoilers: