Folding/Rolling-up boxes in MediaWiki

In MediaWiki, if the Index at the top is large, it becomes show/hideable.

Is there a way to do this with other sections in MediaWiki?

I maintain technical documentation on an internal wiki, and I would like to be able to hide some documentation that 99% of users won't need:

Before installing Massive Application, install the JDK [show+]


Clicking on "Show+" would unroll a <pre> box with the instructions in.

Is this possible?

Since v1.18, out-of-the-box you can do the following (as described here):

<div class="mw-collapsible mw-collapsed">
This text is not collapsible; but the next is collapsible and
hidden by default:
<div class="mw-collapsible-content">{{Lorem}}</div>
</div>

• Of course, the other answer I provided is applicable for wikis that are using versions before MediaWiki 1.18. Feb 5 '13 at 10:55

This is possible, but requires some addition into the MediaWiki:Common.js file in your wiki. Such functionality is already live on the English Wikipedia.

Take a look at Wikipedia:NavFrame for documentation about the usage and to see how to implement it on another wiki (like yours).