2

On a page like Wikipedia's Animal Farm there is a list of characters. Some items in this list could link to their own articles. In the navbox which is another list, at the bottom of this and other pages there are links to these articles.

Because the two lists of links are maintained manually they're not kept in sync. How to connect them, so that only updating one also causes the other to be updated?

Each article usually has an infobox listing aspects that differentiate between the subjects. This can also help to navigate around the subject. It should also by synced in some way. Perhaps the infobox is where the users enter the information that's used by the navboxes and lists.

  • Would it be okay if the list was kept in a third place, using template syntax (or Lua, assuming your wiki has Scribunto)? – svick Nov 4 '14 at 22:14
  • If necessary but the less confusing for the users the better. The wiki has Scribunto and Semantic MediaWiki. It would be nice if each article could also have an info box that has some sort of sync to these two types of lists. – Rob Kam Nov 4 '14 at 22:50
  • Are you asking about MediaWiki only, or wikis in general (many of which don’t have templates or the concept of infoboxes)? – unor Nov 5 '14 at 15:05
  • Only about MediaWiki, I've edited the title to state this. – Rob Kam Nov 5 '14 at 18:02
1

If you have SMW, the solution is extremely simple. You can list the pages in question by adding them to a specific category. The category members can then be listed in the format you prefer.

A simple list, suitable e.g. for use in the middle of text or for a non-distracting navigation box, is then as simple as {{#ask: [[Category:Finnish]] | format=list }}.

Fancier lists can then be produced in any format you consider suitable for the various tasks, see for instance the list of Finnish MediaWikis on WikiApiary which is essentially just:

{{#ask: [[Category:Finnish]]
| format=template
| template=Website card
}}

Of course you can add further conditions to filter the lists as needed, still keeping the list in a central place.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.