Forum:Collaps won't work

Hi, I copied the templates from the deutch Lostpedia for a collaps template for spoilers, but they won't work for the dutch Lostpedia. The first time I adapted the code but I recopied the codes, but ther won't work. Can someone help me with this? I believe I got the simular problem on the dutch RuneScape wiki a few mounths ago. Click the links for the template pages. --Darth Stefan 20:57, 5 July 2009 (UTC)Darth Stefan
 * You need some JS to make it all work. Add the JS from w:c:avatar:User:Joeyaa/Collapse to your local MediaWiki:Common.js. Cheers. (Alternatively there is some rewritten jQuery JS you could use, but it's probably best to stick with this for now) :) ~Joey~  ^Talk^  00:16, 6 July 2009 (UTC)

Thanks it works! --Darth Stefan 17:05, 6 July 2009 (UTC)Darth Stefan

Another problem
Suddenly, it doesn't work. It was, but not anymore. See this page for example. --Darth Stefan 18:24, 10 July 2009 (UTC)Darth Stefan

The ShowHide code rewritten for jQuery is working extremely well
If you grow tired of trying to make the older code from wikipedia work then you might want to switch to the jQuery based code Dantman has recently developed. It is working very well for me at vsk.wikia.com


 * Documentation
 * Code

Feature overview

 * Localization
 * Customize button labels according to site (or user) language preference.


 * Show all / Hide all
 * [show all] and [hide all] buttons can be placed anywhere on a page and in multiple locations.
 * All NavFrame blocks on the page are affected however, collapsible tables are not affected by these buttons. This behavior is by design.


 * Specify collapsed by default
 * A NavFrame block or collapsible table that also uses the collapsed class will be hidden by default but can always be manually expanded.


 * Auto-collapse threshold
 * When the specified number of NavFrame blocks or collapsible tables with the autocollapse class are present on a page then all will collapse by default. The counts are handled separately, so one NavFrame and one collapsible table will not be considered 2.
 * Can be overridden for specific NavFrames if the noautocollpase class is also used.


 * Specify non-collapsible rows of a table
 * Using class="nocollapse" on a row will prevent that row from collapsing.


 * Nesting collapsible content
 * Nesting collapsible tables is supported.
 * Nesting NavFrame blocks is supported.

najevi 23:16, 10 July 2009 (UTC)