Template talk:Dynamic navigation box

From Wikipedia, the free encyclopedia

Contents

[edit] Purpose

This template provides a method of dynamically hiding or revealing large navigation boxes.

[edit] Usage

{{Dynamic navigation box|TITLE=title|CONTENT=content}}

title 
heading of the navigation box
content 
contents of the navigation box. It is not possible to include a pipe ("|") in the contents as this symbol is used to separate parameters; type '|' instead.


[edit] Example

From {{Portals}}:

{{Dynamic navigation box|TITLE=[[Portal:Browse|'''Browse by themes''']]
|CONTENT=
[[Portal:Africa|Africa]] - 
[[Portal:Agronomy|Agronomy]] - 
[[Portal:Algeria|Algeria]] - 
[[Portal:Ancient Egypt|Ancient Egypt]] - 
[[Portal:Archaeology|Archaeology]] - 
[[Portal:Art|Art]]
.
.
.
}}

[edit] History

Added documentation Phil | Talk 09:10, 26 September 2005 (UTC)

[edit] Discussion

[edit] Support for skins other than Monobook

The CSS code to make this work seems to have been included into the Mediawiki:monobook.css, but not in others. Would someone be so kind and enable it for the others ? (Mediawiki:Cologneblue.css, Mediawiki:Standard.css, etc. Maybe it can be included in Mediawiki:Common.css ? -- User:Docu


I oppose this template completely. You're using a template to perform a function which really should be requested/added as a software feature. Templates should be used to replicate text among articles, not change the fundamental navigation structure outside of the article body. -- Netoholic @ 19:33, 2 January 2006 (UTC)

Hiding and showing content is something that should be requested as a built-in to the software, where the Javascript code (currently in MediaWiki:monobook.js can be put through proper development practices, like CVS. -- Netoholic @ 20:04, 2 January 2006 (UTC)
I'm not sure I understand. Is this template not the right way to accomplish a hideable box? How would a software change make this process any easier? And has someone started taking this 'feature request' through the 'proper' channels? -- Ec5618 18:09, 30 January 2006 (UTC)

[edit] Option to hide or show as default

There should be an option to hide or show the content by default. This template is worthless if it's showing everything by default. —Cantus 16:01, 25 February 2006 (UTC)

I don't know how to make it an option within the template, but hidden being the default makes a lot more sense to me so I have tweaked MediaWiki:Monobook.js to make it so. If anyone objects let me know and I'll change it back. Worldtraveller 16:00, 14 March 2006 (UTC)
A great many people object, including me! See your talk page, the Monobook.js talk page and The Village Pump. I( now) understand that you meant well, but this has greatly reduced the usefulness of many templates. I don’t know much about these things, but perhaps another class of template could be created to be hidden by default? -- WikidSmaht (talk) 05:13, 16 March 2006 (UTC)
I like hidden by default, but this should certainly be an option that can be set on a per-template basis. Does anyone know how? — Reinyday, 17:12, 18 July 2006 (UTC)
I also would like to set this box to hidden as default. I can't figure out how this works - does this call the .js application? If so, how? If so, can a different .js be called that is modified to be set to hidden as default? I saw another dynamic navigation box that starts out hidden, but i have no .js experience so i have no idea how this works. Is there a page that explains this? Sorry for the ramble. See Template:WPMILHIST_Announcements for the default hidden navigation boxes. Thanks --Exodio 02:34, 27 August 2006 (UTC)
Not sure, but I think it starts hidden when there's more than one hide/show navbox on the page. Shinobu 00:52, 31 October 2006 (UTC)
If there is more than one, then the first should be open and the remainder closed. What's the point of a series of navigation boxes all closed so that there's no navigation links to click on? Conversely, what's the point of putting a "hide" link on a bunch of boxes which clutter the page—to let the user design the page the way it should have been in the first place, every time he loads it? There is a kernel of excellent usability here, but it has not germinated.
AND WHERE THE HELL ARE THE MAIN DOCS FOR ALL THIS STUFF? I've only been trying to find them for a half hour. Michael Z. 2006-10-31 03:51 Z

[edit] Update for MediaWiki:Cologneblue.js

Would someone update the above to make it work in that skin as well? I'm not sure if that js-page is included though. I made the necessary additions to MediaWiki:Cologneblue.css for this template. -- User:Docu

[edit] Hiding a wikitable

Hi, has anyone figured out, how to add a hide option to large wikitables that the user can expand open if they want to --Cloveious 03:32, 12 August 2006 (UTC)

[edit] WIDTH parameter working?

I can't seem to change the width of the box. I'd like to use 94% (same as {{NavigationBox}} but the WIDTH parameter seems to be ignored. Andrwsc 03:00, 29 September 2006 (UTC)

Never mind, I fixed the bug. Andrwsc 03:13, 29 September 2006 (UTC)

[edit] {{navigation}}

This template looks like it's basically superseded by the template above, which provides v-d-e-links. Shinobu 15:25, 30 October 2006 (UTC)

[edit] What broke it?

The first village on Template:Engadin_villages is now on a separate line. Is it the change from <div> to a wikitable version that broke it? If yes, how can it be fixed? Change it back to div? -- User:Docu

I'm not sure what broke it exactly, but I fixed it by eliminating the returns on each line. —Seqsea (talk) 22:50, 27 November 2006 (UTC)
That was what I had to do to a lot of templates too, but I'm not sure why that should matter. Andrwsc 00:07, 28 November 2006 (UTC)
This leads to a lot of spaghetti. Can we switch it back to the <div> version? (Andrwsc just changed it without explaining what problem this resolved). Currently it's out of sync with the version with the image. -- User:Docu
Sorry for not explaining here. The old version has two significant problems that affect over 3000 articles on the Olympics (namely, articles of the form "Nation at the year Olympics", such as United States at the 1998 Winter Olympics, to provide an example instance). All of these pages include a navigation box that was constructed using this template. The first problem is that some of these navigation boxes are quite large (e.g. recent Games have ~ 200 nation articles) and so the importance of having a functional STATE parameter (defaulting to "collapsed") is high. Second, and certainly a bigger problem, is that the old version produced incorrectly rendered navigation boxes. They were drawn immediately after the previous line of article text. On stub articles like the one above, that would occur in the middle of the vertical span of the infobox on the right, so the box would start with perhaps 65% of the page width available. Also, strangely, the box would end after the end of the infobox span, so that there was a lot of whitespace within the box. It would also result in an irregular polygon shape instead of a simple rectangle. It is hard to explain, but trust me - it was butt-ugly. Andrwsc 05:01, 28 November 2006 (UTC)
Last winter, when I added a few infobox to Olympic skiers, I think I was one of the first to use the template for the infoboxes and they looked fine to me. Odd that they don't work any more. The current solution is not very satisfactory, e.g. St. Moritz has three different formats for the nav boxes. -- User:Docu