Chapter 5. Links

Any web page can have links, but on a wiki, links are critical. Much of the power, expressiveness, and utility of wikis comes from effective linking, leading the reader efficiently from topic to topic. A wiki article without links is like a room without exits.

In this chapter, we’ll discuss:

  • Internal links within a single wiki

  • External links to other websites

  • Interwiki links between wikis

  • Interlanguage links between translations of the same article

  • Graphical links that use graphics instead of text

  • File links to files on a local computer

  • Linking tips for effective wiki articles

Internal Links

An internal link leads to another page on the same wiki. It’s simple to create an internal link: just type the name of the target page surrounded by double square brackets:

[[like this]]

Here’s an example of an internal link placed conversationally within a sentence:

It's cheaper to purchase [[dog food]] in bulk.

This displays a link to the wiki article Dog food.

The links [[dog food]] and [[Dog food]] are equivalent, pointing to the same article. The link [[Dog Food]] with a capital “F” refers to a different article, however. MediaWiki’s rules of case-sensitivity are quirky, but they make sense when you’re used to them. The sidebar Article Titles and Case-Sensitivity” explains these rules in detail.

Note

MediaWiki article titles are generally plain, conversational text, like dog food or building a dog house. Some other wikis prefer “camel-case” article titles, like DogFood or BuildingADogHouse. ...

Get MediaWiki now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.