Manual:Collapsible elements

After 1.17

 * See also jQuery.makeCollapsible documentation for more information about how it works.

Basically all you do is add the class " " to an element.

For example: Gives: This is text is collapsible.

To set the initial state as collapsed add " ", such as seen in the following table:

You can so specify a specific part as being the collapsible content

Gives: This is text is not collapsible. But the next is collapsible and is also hidden by default:

Before 1.17
How to make collapsible tables as seen on the English Wikipedia. This script only applied to tables.

Setup
Copy and paste the following text into your wiki's MediaWiki:Common.js and MediaWiki:Common.css:

Markup
The following markup in pages now makes collapsible sections:


 * Result: