Extension:Expandable tables
From MediaWiki.org
|
Release status: beta |
|
|---|---|
| Implementation | Skin |
| Description | Allows expandable/collapsable tables to be created similar to WikiNews |
| Author(s) | User:Nad |
| Last Version | 1.1.1 (2007-05-10) |
| MediaWiki | > 1.6.0 |
| License | No license specified |
| Download | Extension:ExpandableTables.php |
|
check usage (experimental) |
|
This extension is obsolete
For similar functionality see W:Wikipedia:Collapsible tables.
This extension is a single snippet of code to be included in your LocalSettings.php script, it's only been tested on version 1.6.7. It allows expandable/collapsable tables to be created by giving them a class attribute of "expandable", and a title attribute. If an id attribute is included and set to 1, the table will be expanded by default.
Contents |
[edit] Example usage
{| class='expandable' title='Foo bar table' id=1
|
*foo
*bar
*baz
|}
[edit] Bugs & warnings
- It doesn't currently work in page preview
- The class and title attributes must be first
[edit] Installation
Copy the code from OrganicDesign:Extension:ExpandableTables.php, save it in your extensions directory and include it from your LocalSettings.php file.
[edit] CSS Styles
Here's an example of the CSS styles used for the tables:
.expandable-heading { background-color: #eee; border: 1px solid #aaa; width: 100%; margin: 0.2em 0 0.2em 0; padding: 0; } .expandable-heading td { border: none; padding: 0; } .expandable-link { color: #3D5270; font-weight: bold; font-size: 90%; white-space: nowrap; padding: 0; } .expandable-content { width: 100%; background-color: #f4f4f4; border: none; padding: 0 0.2em 0 0.2em; margin: 0; } .expandable-content td { border: none; margin: 0; padding: 0 0.2em 0 0.2em; vertical-align: top; } .expandable-content td a { white-space: nowrap; }