Click the picture for details

ExpandCollapse

Saltwater Addict

C-SEA Member

A lot of people have been asking about spoilers, how to do them and how to fix them when they break... so I thought I'd make a guide especially for spoilers, since a few people have been having problems with them.

What is a spoiler?
Simply put, a spoiler is something that hides information and prompts the user to click to show it. Here's an example:

Section 1: New Spoiler Wizard
How to make a spoiler
The latest XenForo update brings us a new Spoiler Wizard! This makes creating spoilers easier than ever! Here's how to use it:

Click on the "+" in the media section of the insert-into-post bar:

Click on the "Spoiler" button from the drop down menu:

Next, insert a spoiler name, if you wish to:

Insert the content of your spoiler between the two SPOILER tags:

You're done! Enter the rest of your post (or even more spoilers if you want!) and hit that Post button.

ExpandCollapse

Saltwater Addict

C-SEA Member

Section 2: Plain BB Code
How to make a spoiler
Firstly, when making a spoiler, you need to use the BB Code editor. Using the Rich Text Editor often breaks the spoilers, leaving you with many problems.
Spoilers are very simple to code. In fact, all you need to do is use spoiler tags within the BB Code editor. The code below is the code for the spoiler above:

Code:

[spoiler]This is a spoiler[/spoiler]

Custom named spoilers
Again, very simple. All you have to do is use spoiler=Name and it'll be named Name (open) and Name (close). You can see this below:

Code:

[spoiler=Name]This is a named spoiler[/spoiler]

This is a named spoiler

Even more custom named spoilers
This is a variation of the named spoiler above, but you can add two names; one for open and one for closed. For example, you use spoiler=Open me, Close me an it will display as Open me when closed and Close me when open. You can see this below:

Code:

[spoiler=Open me, Close me]This is a named spoiler[/spoiler]

This is a named spoiler

Formatting spoilers
When formatting a spoiler, make sure that your BB tags are relative. E.g. If you make a bold tag inside the spoiler at the start, make sure that your /bold tag is also inside the spoiler tag. If you move your tags around, your spoiler will either break or duplicate